Hi there,
I'm trying to set up mod_rewrite rules to clean up my URL's.
I have a page colours.php which can hold any of the following vars:
colours.php?s=1
colours.php?s=2
colours.php?s=3
I would like to display these as
colours/red
colours/green
colours/blue
Now I've been trying for quite a while and I just cant seem to get it to recognise the pattern when I include the colour.
However, as a test to see if RewriteRules were working, I tried just setting the base page to direct to colour 3 using the following:
Code:
RewriteRule (.*)colours(.*)$ colours.php?s=3
and this works fine.
As soon as I add the specific colour in the pattern however, it stops working and gives me a 500 Internal Server Error:
Code:
RewriteRule (.*)colours/blue(.*)$ colours.php?s=3
If anyone could point out what I'm doing wrong I'd greatly appreciate it! Thanks