Hi David,
So pleased you have opened this forum up - I have soooo many questions and am so hungry for knowledge!
I am using Magic parser to build a site from the Laterooms API, all is going well but have a question regarding .htaccess rewrites.
I believe that the best URL's are short and with that in mind I am trying to construct the URL's
How do you pass information in a URL, but not necessarily use all the information in the rewrite. For example....
hotel/".$results["REGION_CODE"]."-".$results["REGION_DESCRIPTION"]."-".$results["TOWN_CODE"]."-".$results["TOWN_DESCRIPTION"]."
The above URL will pass through 4 variables. I know how to rewrite using all 4, but is it possible to use one variable for the rewrite but still pass the others through for use in the script.
RewriteRule ^hotel/(.*)-(.*)-(.*)-(.*).html$ hotel_results.php?region_code=$1®ion_description=$2&town_code=$3&town_description=$4 [NC]
I would like the URL to look like this, but still have the other 3 variables available to use. Does this make sense?
RewriteRule ^hotel/(.*).html$ hotel_results.php?town_description=$1 [NC]
Also is it best to end a rewritten URL with / or .html?
Thanks,
Simon