Hi all!
I'm new to this forum so please be kind.
I'm trying to do what most people are doing but with a few variations which I just can't make work:
I have the following URL which I want to change as illustrated but I also have directories like /images/ and /css/ that I need to work as normal.
From:
http://www.mydomain.com/category/page
To:
http://www.mydomain.com/index.php?cid=$1&id=$2
I also want to illustrate a hierarchy of categories to appear like directories:
From:
http://www.mydomain.com/category/sub_category/page
To:
http://www.mydomain.com/index.php?cid=$ ... d=$2&id=$3
and perhaps more sub directories.
I have tried the following and it seems to show the index.php but the variables don't work, and the images in /images/ dont show..I even tried aliases for these directories...
RewriteEngine on
RewriteCond %{REQUEST_URI} ^/([a-zA-Z0-9]*)/([a-zA-Z0-9]*)
RewriteRule ^(.*) index.php?cid=$1&id=$2 [L]
I hope someone can shed some light on this....it's doing my head in!
Thanks for the help!
Simon H