• Hi Guys

    I’ve managed to make a hash of trying to prepare to transfer my WP files to a new server, and am now in a bit of trouble.

    Basically, I have changed the site URL’s defined in the General Settings from the current location to the new sever. As a consequence and having realised my error, I can’t get back into wordpress to rectify the error.

    I guess that I should be able to rectify this via the control panel, but how and where etc. is where I would appreciate some direction please, as I’m very ignorant file structures and content.

    I’m getting the following show in the address line, where xyz and abc replace the real content:

    https://xyz.net/wp-login.php?redirect_to=http%3A%2F%2Fabc.eu%2Fwp-admin%2Foptions-general.php%3Fsettings-updated%3Dtrue&reauth=1

    Any help would be much appreciated.

Viewing 6 replies - 1 through 6 (of 6 total)
  • https://codex.www.ads-software.com/Changing_The_Site_URL
    https://www.google.com/search?q=change+wordpress+site+url

    Unless you intend to change your site’s domain name, there is no need to change anything in order to have your site run at a different server. One exception I know about, however, would be with a plugin (such as BulletProof Security) that uses “absolute server path” since that will be different at the new location. So in a case like that, the plugin would have to be deactivated and deleted or uninstalled and then re-installed so it can know the new path.

    @basils57 – You can use phpMyAdmin in your web host control panel to edit your database tables to correct the URL’s or you can use code in your wp-config.php file to get back into your site: https://codex.www.ads-software.com/Changing_The_Site_URL

    Thread Starter basils57

    (@basils57)

    Thanks for the replies guys.

    I’ve read through https://codex.www.ads-software.com/Changing_The_Site_URL
    and decided to try to use ‘Edit functions.php’. However, the only functions.php file I seem to be able to locate is within wp-includes. Is this the right file to edit? The only other file I can see is ‘admin-functions.php’ within wp-admin.

    The functions.php you would use for this is a file in your theme.

    • This reply was modified 8 years, 1 month ago by leejosepho.
    Thread Starter basils57

    (@basils57)

    Sorry leejosepho, but I’m unable to see a standalone functions.php file.
    My current hosting contains a few sub-domains and I’ve been looking in the relevant sub domain directory. There appears to be no reference to the theme or functions.php in the files in there?

    I think instead Imight try editing the wp-config.php file as suggested in ‘Changing the Site URL’, but I note that the can’t be edited on the General Settings page once back into the site?

    Apologies for the ignorance; am I missing something here?

    Making changes at Settings > General is only for updating a database just prior to pointing or assigning a new or different domain to your WordPress installation. Those settings tell WordPress what to expect coming in and where to find your installation. The functions.php file you are looking for will be in the installation’s wp-content/themes/(youractivetheme)/ folder. Using wp-config.php instead should also work, and then the added code in either location should be commented (or removed) to deactivate it.

    • This reply was modified 8 years, 1 month ago by leejosepho.
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘How to fix an edited site URL’ is closed to new replies.