Forum Moderators: phranque
RewriteRule ^([a-z]+)/([a-z0-9]+)/([a-z0-9]+)/([a-z0-9_]+)$ /page.php?v1=$1&v2=$2&v3=$3&v4=$4 [L]
RewriteRule ^([a-z]+)/([a-z0-9]+)/([a-z0-9]+)$ /page.php?v1=$1&v2=$2&v3=$3 [L]
RewriteRule ^([a-z]+)/([a-z0-9]+)$ /page.php?v1=$1&v2=$2 [L]
RewriteRule ^([a-z]+)$ /page.php?v1=$1 [L]
I am just hoping their is a way to combine all these into one simple rewrite rule. If need be, I could make all levels ([a-z0-9_]+) if thats helps in combining them all into one RewriteRule.
One more question,
If it is possible to combine the above into one line, is it possible to also add this line to the mix,
RewriteRule ^(search)$ /page.php?v1=$1 [QSA,L]
I need QSA for this and only this one rewriterule, is it a bad idea to add QSA to rewriterules that don't need it?
RewriteRule ^search$ /page.php?v1=search [QSA,L]
RewriteRule ^([a-z]+)/?([a-z0-9]*)/?([a-z0-9]*)/?([^a-z0-9]*)$ /page.php?v1=$1&v2=$2&v3=$3&v4=$4 [L]
If your script can't handle the blank vars, then it won't work.
Replace all broken pipe "¦" characters with solid pipes before use.
Jim