Cannot get 301 redirection in htaccess to work (either Redirect or Rewrite)

The ^ in your rewriterule means the URL must begin with the postname, as in your new structure – so what you’re saying in that second line is, “redirect http://www.example.com/postname to http://www.example.com/postname“. So it’s the ^ that’s throwing things off. If you were previously using URLs like http://www.example.com/categoryname/postname/ then I would suggest instead: RewriteEngine On … Read more

WordPress multisite and redirect to subpage

An htaccess rewrite rule ought to do it. Check out this post https://mediatemple.net/community/products/dv/204643270/using-htaccess-rewrite-rules for examples of what you might do. The one you use will depend on whether content in zzz is the same as the bbb site. If you just want to redirect everything (any page) on bbb to zzz, then this should work: … Read more

Unable to access WP test site

WordPress stores the site URL in a few places in the database in serialized arrays, which can break if you do a simple search & replace on the database. You need to use a tool like this which is aware of serialized arrays to do the replacement. You can bypass the broken URLs enough to … Read more

Local domain remap with proxy : Infinite 301 redirect, bad URL typo

Found the problem / the solution: while using the proxy, the servers variable REQUEST_URI is not the same using FoxyProxy, server var ‘REQUEST_URI’ return the full url: $_SERVER[‘REQUEST_URI’] -> “hxxp://mydomain.com/theurl” using windows host file, server var ‘REQUEST_URI’ return just the end of the url: $_SERVER[‘REQUEST_URI’] -> “/theurl” so I added this to the wordpress index.php … Read more