开发者

Editing a Wordpress Site Locally?

开发者 https://www.devze.com 2023-03-30 20:22 出处:网络
Okay, so I\'m helping a friend out with his site (that he designed in wordpress). I don\'t like the idea of working solely on a live site, so I copied it down to my local server on my mac. Here\'s the

Okay, so I'm helping a friend out with his site (that he designed in wordpress). I don't like the idea of working solely on a live site, so I copied it down to my local server on my mac. Here's the issues I'm having in terms of editing it.

  1. Editing via SQL (SequelPro), throws the site back to nothing, even if I make a VERY slight change in the html that one would see on the Wordpress end.
  2. Even if I try to go to the local site adm开发者_运维技巧in, it leads to the live. Any ideas on this? localsite/wp-admin ....


  1. What do you mean, "throws back to nothing"? You'll need to provide a bit more detail on what HTML you're adding, and where you're adding it.

  2. When you move a Wordpress site to another domain/location whether they be local or otherwise, you need to do a find replace on the MySQL exported file to replace livesite.com with localsite.dev, otherwise Wordpress will keep linking to the livesite.com.


You can edit the wp-config.php file to override the site url settings that are in the database.

define( HOME_URL, 'http://localhost' );
define( WP_SITEURL, 'http://localhost' );  //This is where WordPress is installed.

This will allow you to access the site locally.

0

精彩评论

暂无评论...
验证码 换一张
取 消