Url rewrite one step further
I am using this rule now and it is applied to my members...
RewriteRule ^member/([0-9]+)/([^.]+).html$ member.php?id=$1&name=$2
And开发者_JAVA百科 it is looking like this:
http://www.mysite.com/member/1/Foo_Smith.html
I want to take this further and deeper into the site like this:
http://www.mysite.com/member/1/Foo_Smith/Gallery.html http://www.mysite.com/member/1/Foo_Smith/Gallery/viewPhoto/nice_picture_i_took.hmtl
Pages in my root is galleri.php and viewPhoto.php
Any ideas if this is possible and any examples on how to achive this?
Best regards, Joakim
RewriteRule ^member/([0-9]+)/([^./]+)\.html$ member.php?id=$1&name=$2
RewriteRule ^member/([0-9]+)/([^/]+)/Gallery\.html$ gallery.php?id=$1&name=$2
RewriteRule ^member/([0-9]+)/([^/]+)/Gallery/viewPhoto/([^/]+)\.html viewPhoto.php?id=$1&name=$2&photo=$3
I haven't tested it, but I think it should work.
精彩评论