hi, I have urls like http://www.<mysite>.com/browse.php?cid=1 and I want to make them seo friendly with relevant names like http://www.<mysite>.com/this-is-title.php where "This is Title" is the title of the page ? how can I do this ?
yes I do have access to .htaccess but don't have enough kowledge of mod-rewrite rules. I tried some codes by reading nintendo's FAQ but the code didn't seemed to be working.
What have you got so far? It'll save a lot of hassle if you include the ID in your new 'friendly' url as well though. /235-this-page-title.php to /browse.php?cid=235 RewriteRule ^([0-9]+)-(.*)\.php browse.php?cid=$1 [L,QSA] Code (markup): ^ means must start with [0-9] matches any number + means we want 1 or more number Put that in brackets so it's accessible for our rewrite destination. Then we have (.*) - the period indicates any character and the * means 0 or more times. Add the .php extension, escaping the period special properties with a backslash. Put that all together in our desired format to get: ([0-9]+)-(.*)\.php That means we're matching: 452-pie.php 423932-.php 3-chickens-can-fly.php but not 404.php (no dash) article953-pie.php (doesn't start with a number) The rewrite destination is fairly self-explanatory. Then we add the L flag so mod_rewrite knows not to apply any more rules. And the QSA for Query String Append: 34-title.php?show=printable would become browse.php?cid=34&show=printable. Hope that helps..