WordPress website After moving

Source: Internet
Author: User
Tags mysql host wordpress database

1. Modify the Wp-config file, it is best not to use Notepad to modify, with notepad++ or UltraEdit and other editors, the database information into your new space database information, as follows:

/** Name of WordPress database */

Define (' db_name ', ' Your new Spatial database name ');

/** MySQL Database User name */

Define (' Db_user ', ' Your database user name ');

/** MySQL Database Password */

Define (' Db_password ', ' Your database login password ');

/** MySQL Host */

Define (' Db_host ', ' Your database address ');

Fill in your new host space's database name, database username and password. Note that the MySQL host this default is ' localhost ', if you are a Windows host, without modification, if it is a Linux host, you may need to fill in the database address.

2. Enter the new space phpadmin modify the database: Modify the database table Wp_options in the "SiteURL" and "Home" field values, changed to your new domain name;

3. After the use of the domain name resolution to space, login to your WP backstage, modify your blog address for your new domain.

4. The original article has the link or the picture is uses the former domain name address, therefore also must revise those address. You can modify the database directly in Phpadmin or velvet-blues-update-urls this plugin (recommended). For example, in Phpadmin, execute the following statement:

UPDATE wp_options SET option_value = REPLACE (Option_value, ' old address ', ' new address ');

UPDATE wp_posts SET post_content = replace (post_content, ' old address ', ' new address ');

UPDATE wp_posts SET post_excerpt= replace (post_excerpt, ' old address ', ' new address ');

UPDATE wp_posts SET guid= replace (GUID, ' old address ', ' new address ');

WordPress website After moving

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.