Forum Moderators: phranque
redirecting the URL by mod_rewrite, server internal, without 301
it makes no difference, if it's a 301-redirect or "internal rewrite without 301"
[edited by: phranque at 1:40 am (utc) on Aug 11, 2014]
[edit reason] unlinked URL [/edit]
RewriteRule ^(onedir|otherdir|thirdddir)/(\w+)\.html http://www.example.com/$1/$2 [R=301,L] At the moment my htaccess has only the common standard code to redirect non-www to www
i.e. RewriteRule without the [R=301,L]
RewriteRule ^((onedir|otherdir|thirdddir)/\w+)\.html /index.php?$1 [L] # 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
[edited by: phranque at 7:39 pm (utc) on Aug 17, 2014]
[edit reason] exemplified domain [/edit]
<IfModule mod_rewrite.c>
RewriteEngine On
The sequence of #4 and #5 is not contrary to
"So immediately BEFORE the index.php?blahblah rule (the one that's the meat of every CMS) you insert one that says something like
RewriteRule ^((onedir|otherdir|thirdddir)/\w+)\.html /index.php?$1 [L]"
RewriteRule ^((onedir|otherdir|thirdddir)/\w+)\.html /$1
[edited by: phranque at 10:11 pm (utc) on Aug 21, 2014]
[edit reason] exemplified domain [/edit]