0

I migrated my site to a new server. Everything seems to be fine, but the browser is redirected to the frontpage when I save configurations in either the "W3 Total Cache" plugin or in "Duplicate post" plugin. It does save the edits, but it´s annoing with the redirect.

For example when I press purge all caches from W3 Cache, it is redirected to

www.mysite.com/?w3tc_note=flush_all

I can´t find a solution that solves it. I tried with:

define('WP_HOME','http://example.com');
define('WP_SITEURL','http://example.com');

In my wp-config.php

And with these google results: Redirecting to home-page when saving any edited code https://wordpress.org/support/topic/wordpress-5-0-beta3-redirects-to-wp-admin-edit-php-after-hitting-enter-key/

I also looked at the wp_options in the DB. But seems allright.

I tried to change the wp permanent link options in the admin settings too.

The "Duplicate post" plugin was installed after the site migration.

0

Okay, I found a solution. To anyone in the future having this problem here's what i did:

  • I used the plugin "Duplicator" and made a package of the site.
  • Then i downloaded the installer and the archive.
  • I then deleted everything in the database and on the ftp.
  • Then I transfered the archive and installer file to the FTP and run the installer.php

Now everything works again :)

0

It is a bit hard to really know what is going on. But a best "guess" is that you have a plugin that is redirecting and/or conflicting with the theme. By process of elimination, I would deactivate all the plugins and see if the problem still exists. If it disappears, reactivate, one by one. Somewhere there is a conflict and doing a redirect.

A secondary effort would be, after all the plugins have been disabled and assuming it still exists, then change themes.

You have to narrow this down to the most basic element.

  • Thanks! But after deactivating all plugins and switching to one of the twenty theme + deleting cookies, it still does the redirecting error :( – JonasB Mar 8 at 11:32
  • then I would be looking at some malware or changes to functions.php. Something is causes the redirect. – Debbie Kurth Mar 8 at 17:31
  • Thanks! I can´t see anything in the functions should be wrong though. And nothing else seems to be wrong. I also tried to look through the DB for any hardcoded URLs – JonasB Mar 12 at 10:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.