今天WP中文论坛一网友问我win主机下wordpress不支持中文标签问题如何解决,GOOGLE之,解决办法如下:
修改wp-includes/rewrite.php
function get_tag_permastruct() { if ( isset($this->tag_structure) ) return $this->tag_structure; if ( empty($this->permalink_structure) ) { $this->tag_structure = ''; return false; } if ( empty($this->tag_base) ) $this->tag_structure = trailingslashit( $this->front . 'tag' ); else $this->tag_structure = trailingslashit( '/' . $this->root . $this->tag_base ); $this->tag_structure .= '%tag%'; return $this->tag_structure; }
if ( empty($this->permalink_structure) ) { $this->tag_structure = ''; return false; }
这里的判断加个 ! 号即可 ,即变成 :
if ( ! empty($this->permalink_structure) ) { $this->tag_structure = ''; return false; }
From:http://www.ihacklog.com/wordpress/problems/solution-to-wordpress-chinese-tag-problem-under-win-server.html
声明:本文采用 BY-NC-SA 协议进行授权,如无注明均为原创,转载请注明转自 你好!刘
本文地址:Win主机下wordpress不支持中文tag标签解决办法
本文地址:Win主机下wordpress不支持中文tag标签解决办法
发表评论