2

A post has a js redirection script. Full Stop. If you're redirecting anything in JS, start from there as the first failure point. There's really no reason anything should be redirecting from JS on the front end. There are plenty of redirection plugins out there to handle any redirection rules you might need. Delete the script, redirect the page properly, ...


1

If you have a thank-you-page with same slug in all sites you can do: add_action('comment_post_redirect', 'redirect_to_thank_page'); function redirect_to_thank_page() { return get_bloginfo('url').'/thank-you-page'; } get_bloginfo('url') detects the subsite you're currently in


1

If that redirection script is written in the content section of the post, it is probably being called in with the rest of the content on the category page. You could add a URL check to your javascript that would look like this: if(document.URL.indexOf("foo_page.html") >= 0){ window.location.replace("http://www.w3schools.com"); } And add in your ...


1

Look in your wp_options database table for the siteurl and home options and check these are using your local URL. As Captain S commented, these can also be overridden in your wp-config: define('WP_HOME', 'http://www.localsite.test'); define('WP_SITEURL', 'http://www.localsite.test');


Only top voted, non community-wiki answers of a minimum length are eligible