Forum Moderators: phranque
I've been beating my head against the wall with this one.. The only thing I can think of is that the domain name I'm testing this rewrite on is not live, although I've edited my host file to map the domain to the ip.
Here's the file.. again, it's the first rewriterule before # -frontpage-
RewriteEngine On
RewriteRule ^subfolder/([0-9]{4})/([0-9]{1,2})/(.*).html$ /index.php [QSA,L]
# -FrontPage-
IndexIgnore .htaccess */.?* *~ *# */HEADER* */README* */_vti*
<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthName www.mysite.com
AuthUserFile /home/subfolder/public_html/_vti_pvt/service.pwd
AuthGroupFile /home/subfolder/public_html/_vti_pvt/service.grp
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME}!-f
RewriteCond %{REQUEST_FILENAME}!-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Thanks in advance,
Triumph
RewriteRule ^subfolder/([0-9]{4})/([0-9]{1,2})/(.*).html$ /index.php [QSA,L]
What's the url you're trying to match? Right now, this will only match URLs like this:
subfolder/2006/11/foo.html
Did you grab it from somewhere or write it yourself? If you grabbed it, it looks like you're supposed to replace "subfolder" with the name of an acutal folder, so something like this
RewriteRule ^foo/([0-9]{4})/([0-9]{1,2})/(.*).html$ /index.php [QSA,L]
And I'm not sure how RewriteRules work in .htaccess, maybe someone else can help. Do they get the full URL, including leading slash, or just the relative URL? If the former, you need to remove the line-front anchor:
RewriteRule foo/([0-9]{4})/([0-9]{1,2})/(.*).html$ /index.php [QSA,L]