skip to Main Content

.htaccess redirect urls with spaces – Apache

I am trying to redirect all invalid urls to my index.php file via my .htaccess file. Unfortunately I keep getting an Apache error. My .htaccess file RewriteEngine on RewriteCond %{REQUEST_URI} !.(?:css|js|jpe?g|gif|png)$ [NC] RewriteRule ^([a-zA-Z0-9-_/]*)$ index.php?p=$1 RewriteRule ^([A-Za-z0-9s]+)$ index.php?p=$1 [L]  This invalid url shoud redirect…

VIEW QUESTION
Back To Top
Search