WordPress .htaccess to consider blog as directory

This is not answering the exact question you posed, but as as far as I am concerned, your current attempt is the wrong approach to solve the problem of wrong image paths after moving anyway. Rather than what you are attempting to do, either replace the image paths in the database, or redirect those. While … Read more

Need help rebuilding lost htaccess file

It’s tricky to do this… Requests for any other subfolder (assuming it exists) should go through to to the folder requested (e.g. mydomain.com/proxy or mydomain.com/shop are passed through to their respective folders /proxy and /shop). …in combination with… Requests for subfolders which do not exist, should be routed through to mydomain.com/site …without losing the ability … Read more

How to turn this .htaccess rule into a dynamic rule with add_rewrite_rule, et al?

Try this and follow the same structure to add more rewrite rules or query vars: add_filter(‘query_vars’, ‘my_query_vars’); function my_query_vars( $vars) { $vars[] = “land”; $vars[] = “expert”; return $vars; } // Add the new rewrite rule to existings ones add_action(‘init’,’my_rewrite_rules’); function my_rewrite_rules() { add_rewrite_rule( ‘land/(.+)/?$’ , ‘index.php?land=1&expert=$matches[1]’ , ‘top’ ); } Don’t forget to flush … Read more