Mod Rewrite one variable or another on single rule?
Would it be possible to call one variable or another?
My type page gets either tag
or type
variables.
The code I have doesn't work, it only catches the first vari开发者_C百科able, tag
.
How can I combine it into one or if not possible how do I make both work?
ex:
RewriteRule ^hen/egg/([^/\.]+)/?$ type.php?tag=$1 [L]
RewriteRule ^hen/egg/([^/\.]+)/?$ type.php?type=$1 [L]
Use different virtual paths for them:
RewriteRule ^hen/tag/([^/\.]+)/?$ type.php?tag=$1 [L]
RewriteRule ^hen/type/([^/\.]+)/?$ type.php?type=$1 [L]
精彩评论