Adding htaccess rules for api and converted associative dirList to regular array