How do I move a wordpress directory?

Source: Internet
Author: User
In the abc.com domain name built a wordpress station, under the Abc.com/def also built a WordPress station.
Now want to move abc.com/def to abc.com as the main station, that is, open abc.com after access to the content of the original abc.com/def.
How do I ask?

Reply content:

In the abc.com domain name built a wordpress station, under the Abc.com/def also built a WordPress station.
Now want to move abc.com/def to abc.com as the main station, that is, open abc.com after access to the content of the original abc.com/def.
How do I ask?

Just move one file:

    1. Move the index.php in the Def directory to the root directory, which is the directory accessed by abc.com, and make sure that abc.com is turned on index.php, not index.html;
    2. In the index.php under the root directory:
      require( dirname( __FILE__ ) . '/wp-blog-header.php' );
      Change to:
      require('./def/wp-blog-header.php');
    3. Add the following code in def/wp-config.php:

      Define (' Wp_home ', ' http://abc.com ');
      Define (' Wp_siteurl ', ' http://abc.com/def ');

      Define (' Cookie_domain ', ' abc.com ');
      Define (' Wp_content_url ', ' http://abc.com/def/wp-content ');
      Define (' Wp_plugin_url ', ' http://abc.com/def/wp-content/plugins ');

    1. All the files move under Webroot.
    2. Modified. htaccess
    3. Modify DB URL Record
  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.