URL rewrite problem in WordPress plugin

If you want a rewrite rule that loads a post type archive from a different URL, the simplest way is via an internal rewrite, which doesn’t get inserted into .htaccess. Internal rewrites map URLs to query arguments, and must result in a successful main query: add_rewrite_rule( ‘some_url/?$’, ‘index.php?post_type=yourcpt’, ‘top’ );

Pretty URL via Rewrite

It’s the redirect in htaccess that will route the “pretty” url into the real querystring based url that is the issue. So, it would seem you need to “remove” the /{nicename} portion from the “pretty” URL of the form https://example.com/members-list-profile/{nicename}/?uid=XX. Try something like the following at the top of your .htaccess file (before the WordPress … Read more