Pretty URLs and rewrite
Pretty URLs and rewrite
Pretty URLs and rewrite
Rewrite permalink for specific posts
Changing URL scheme, mod_rewrite not helping
Within your rewrite() method add: add_rewrite_tag(‘%state%’,'([^&]+)’); add_rewrite_tag(‘%city%’,'([^&]+)’); That will keep the query_vars you added within the url, and prevent it from being stripped.
Is your Blog page the one that’s set in the back end at Settings > Reading > Posts page? If so, try checking for that in your first function: /* Add .htm extension to Page URL Links */ add_action(‘init’, ‘htm_page_permalink’, -1); function htm_page_permalink() { global $post; if( get_option( ‘page_for_posts’ ) == $post->ID ) { // … Read more
How to pass url as a parameter in a add_rewrite_rule
Add parameter to URL
URL Rewrite and add_query_var not working
How to rewrite AJAX call URL to admin-ajax.php to match REST style URLs
Turns out I was being dumb. The rule is ‘$’