OK I don’t know if I am asking something thats been asked before or not because htaccess makes my brain mush out my ears.
My htaccess currently does this:
www.domain.co.uk/index.php?Pram1=Val1&Pram2=Val2
becomes
www.domain.co.uk/Pram1/Val1/Val2
using
RewriteRule ^Pram1/([^/]*)/([^/]*)/$ /index.php?Pram1=$1&Pram2=$2 [L,QSA]
Huzzar that works BUT when some one goes to:
www.domain.co.uk/Pram1/
I want it to load like a welcome page…. I know how to handle the PHP but dont know how to get the rewrite to to be kind on the blank prams.
I maybe didn’t get your question, but you could do the following:
Add a new rewrite rule:
This would be the easiest to maintain and the easiest to read. I would go this way.
Make the other params optional:
This should work (I did not test this). Pram1 and Pram2 would both be in the query string and would, in case of http://www.domain.co.uk/Pram1/ contain an empty string.
But I strongly suggest to use the first version. It might not seem to be too flexible, but it is really easier to maintain.