• Hi guys,
    I am just learning how to use wordpress so don’t make fun of me ??
    I have localized my website in 3 languages and wanted English to be the starting language. Sooo, I tried different options and finally added to my domain name /lang_en code…
    Bad idea, the site stopped working and I cannot enter the admin panel to change what I’ve done.
    What can I do to re-enter the panel?

Viewing 1 replies (of 1 total)
  • /* Leave everything else alone in wp-config.php all the way
    /* down to "That's all, stop editing! Happy blogging."
    /* Add the following immediately above (or replacing) that line:
    ** WordPress supports an automatic relocation method intended as quick assist
    ** for getting a site working after relocating it from one server to another.
    * After the "define" statements and just before "That's all, stop editing!"
    * Add a slash '/' at the end of this next line to run it:
    /***toggle on/off*
    define('RELOCATE',true);
    /** Next Login as normal after being absolutely certain of the address being sent from your browser.
    ** Then look again in your browser's address bar to verify you have logged in at the correct server.
    ** If this is the case...
    ** Next go to Dashboard > Settings > General to verify and save those address settings.
    ** Once the above has been completed, either remove the above 'define('RELOCATE',true);' line
    ** or comment it out with '//' or change the 'true' value to 'false' or just remove the '/' toggle.
    * Note: When the RELOCATE flag is set to 'true', the Site URL will be automatically updated
    * to whatever path is being used to access the login screen. This will get the admin section
    * up and running on the new URL, but it will not correct any other part of the setup.
    * Those will still need to be altered manually.
    /**
    * That's all, stop editing! Happy blogging. */

    Adding and enabling that near the bottom of wp-config.php should get you back in, then remove or disable that and use either of these to straighten out your URL…

    Near the top of wp-config-php:

    <?php
    /**
    * The base configurations of the WordPress.
    *
    * @package WordPress
    */
    /*-either-*/
    /** @ root/wp-config.php: /*toggle on/off*
    define('WP_HOME','https://domain.com');
    define('WP_SITEURL','https://domain.com');
    /*-or-*/
    /** @ root/wp-config.php: /*toggle on/off*
    define('WP_HOME','https://www.domain.com');
    define('WP_SITEURL','https://www.domain.com');
    /*-end-*/

    At the top of functions.php in your theme:

    <?php
    /*-either-*/
    /* @ theme/functions.php /*toggle on/off*
    update_option('siteurl','https://domain.com');
    update_option('home','https://domain.com');
    /*-or-*/
    /* @ theme/functions.php /*toggle on/off*
    update_option('siteurl','https://www.domain.com');
    update_option('home','https://www.domain.com');
    /*-end-*/

    After using either of those, remove or disable it and go to Dashboard > Settings > General to check and to fully save (if it is correct) what you see there.

Viewing 1 replies (of 1 total)
  • The topic ‘Changed www of the site in admin panel’ is closed to new replies.