方法一:修改字符编码
第一步:wp-includes/class-wp.php153 行
$pathinfo = isset( $_SERVER['PATH_INFO'] ) ? $_SERVER['PATH_INFO'] : '';
改为
$pathinfo = isset( $_SERVER['PATH_INFO'] ) ? mb_convert_encoding($_SERVER['PATH_INFO'],'utf-8', 'GBK') : '';
第二步:wp-includes/class-wp.php 157 行:
list( $req_uri ) = explode( '?', $_SERVER['REQUEST_URI'] );
改为
list( $req_uri ) = explode( '?', mb_convert_encoding($_SERVER['REQUEST_URI'], 'utf-8','GBK') );
方法二:不用中文路径,在设置-->固定链接里,使用其他url方法,如图
上一篇 : 虚拟主机域名绑定和数据库备份
下一篇 : MYSQL数据库导入