wp中文标签分类404的解决办法 wordpress中文标签

wp_wordpress中文标签分类404的解决办法——如图:

0660hf22x3a871

解决这个问题需要修改源文件,请大家在修改前先备份简单说就是复制一份放在那里在修改!),其实很简单只要注释掉一行代码就行!

1.FTP登录到网站目录找到wp-include文件夹并打开,找到class-wp.php文件,下载到本地修改或者在线编辑都行;

2.对class-wp.php文件进行如下修改即可完美解决。

153 行:

$pathinfo = isset( $_SERVER['PATH_INFO'] ) ? $_SERVER['PATH_INFO'] : '';

修改为:

$pathinfo = isset( $_SERVER['PATH_INFO'] ) ? mb_convert_encoding($_SERVER['PATH_INFO'], 'utf-8','GBK') : '';

157 行:

list( $req_uri ) = explode( '?', $_SERVER['REQUEST_URI'] );

修改为:

list( $req_uri ) = explode( '?', mb_convert_encoding($_SERVER['REQUEST_URI'], 'utf-8', 'GBK') );

再罗嗦一句,大家在修改代码的时候一定要做好标记,方便你想改回去的时候不用再四处查找咯!

3、至此整个修改完成,保存文件或者是上传覆盖!

yiguochun

yiguochun(http://blog.0660hf.com/)0660SEO博客是以seo网站优化,Seo学习,sEO知识,SEO网络推广技巧及站长分享经历的媒体博客,为SEO爱好者和广大站长提供一个SEO案例分享和交流的平台,从分享SEO分享交流过程中带来更多的心满意足。

You may also like...

1 Response

  1. normally like your web page nevertheless, you have to check the punctuation with a few of your posts. A lot of them tend to be rife with spelling issues i believe it is really worrisome to tell the reality even so I’m going to undoubtedly can come again just as before video youtube terfavorit.

发表评论

电子邮件地址不会被公开。