How to create custom URL user friendly?

I have a very peculiar requirement, hopefully I can explain it without
being too confusing. I created a page template where I list some
state’s city, let’s say the URL is like this:
http://www.example.com/states/?q=ohio

and i would like to do it like http://www.example.com/states/ohio/

i also used add_rewrite_rule but it’s does not given me output
that i want.

so how could i do fix ?

Read more here: How to create custom URL user friendly?

Leave a Reply

Your email address will not be published. Required fields are marked *