views:

17

answers:

2

Can anyone explain to me why this rewrite rule doens't work:

RewriteRule ^architecture/([a-zA-Z_]+)/(.*).html$ web/index.php?field=1&sub=$1&name=$2

on this url: http://localhost/greenlinked1-6.com/architecture/projects/84-test-deeplink-test.html

And what I should do to get it working. I've tried to find the answer in several articles but I can't figure it out.

A: 

check that u havn't used RewriteBase / just remove & try again...

Vaibhav Gupta
A: 

Your .htaccess file should be placed in the directory greenlinked1-6.com. Make sure there are no conflicting rules, like this:

RewriteRule ^(.+)$ $1 [L]
# This line will never be be matched
RewriteRule ^architecture/([a-zA-Z_]+)/(.*).html$ web/index.php?field=1&sub=$1&name=$2
Lekensteyn
The .htaccess was in place. Your comment about conflicting rules put me in the right direction though. There is a conflicting rule below this one. I always thought that the first match is applied but apparently that isn't so.
Abel
Is your question answered? If not, provide more details.
Lekensteyn
It's answered, thanks. The conflicting rule was the cause.
Abel