Whenever my WP website gets accessed by the url: http://mywebsite.com/subfolder/whatever/else
I want it to be rewritten to: http://mywebsite.com/whatever/else
I have tried many many techniques I have found here, but none of them were successful. Is there a precise way and place within the .htaccess in which I can insert the rewrite rule?
My .htaccess is already pretty messy due to many rewrite conditions regarding security, but I guess I should do something within the following lines?
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Thank you!