Hi guys!
I was wondering if anyone has any decent references for mod_rewrite?
Ive been scouring the web and found a few cheat sheets for it and managed to come up with
Options +FollowSymLinks
RewriteEngine on
RewriteRule search/(.*)/(.*)/?(.*)/(.*)/?(.*)/(.*)/?(.*)/(.*)/?(.*)/(.*)/$ /search.php?$1=$2&$3=$4&$5=$6&$7=$8
which works ok if all the 4 varibles are present. However I want to be able to pass different amounts at once.
e.g.
cat/1
cat/1/item/2
cat/1/sort/asc
cat/1/sort/dec/filter/type
what ive done allows me to have them in what ever order, which is fine - however if they are not all present it dies.
is it possible for it to have as many or few items as needed?
cheers in advance
Fred