![](/img/trans.png)
[英]Wordpress get_bloginfo('template_directory') returns hostname instead of website url
[英]How to edit get_bloginfo('template_directory') to localhost instead of real domain?
我试图将WordPress网站安装到本地目录。
get_bloginfo('template_directory')
返回http://realdomain.com
而不是localhost
。
我如何以及在哪里更改?
define('WP_HOME','http://siteurl'); define('WP_SITEURL','http://siteurl');
将这两行放在您的wp-config.php文件中
您需要在选项表中更新home和siteurl。
您可以在“ settings > general
进行更改,但是在执行此操作时可能要格外小心。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.