Current pattern is http://example.com/questions.php?qcid=25&name=java and I want to make it http://example.com/25/java where qcid must be [0-9] and name must be readable and encoded. If it comprise of more than 1 word then ‘-‘ hyphen must be there between them. For example object-oriented.
Current pattern is http://example.com/questions.php?qcid=25&name=java and I want to make it http://example.com/25/java where qcid must
Share
In .htaccess
In php, you’ll need to capture name and strip the hyphens and fix the caps if needed. As an example, lets say we want the name to be lower camel cased: