更新升级到WordPress 2.9后Simple Tags插件不能运行的解决办法

今天打开博客后台看到 WordPress 2.9 更新提醒,因为刚刚备份完。所以想都无想点了升级,很快就升级成功。

但再次回到后台首页提示:Simple Tags can’t work with this WordPress version!  Simple Tags 插件问题

去官方插件网站看了一下:写着

“Simple Tags 插件不能 Simple Tags is the successor of Simple Tagging Plugin This is THE perfect tool to manage perfeclty your WP 2.3, 2.5, 2.6, 2.7 and 2.8 tags

原来在当前 Wp2.9 版本工作上不兼容,最高版本检查到wp 2.8 只好在官网继续看找到了:

Nothing in 2.9, as far as I can see, that will actually break Simple Tags. The error is thrown because the author has hardcoded a version check.

If you edit the plugin via the editor interface, find this line (near the top):

if ( strpos($wp_version, '2.7') !== false || strpos($wp_version, '2.8') !== false) {

and change it to

if ( strpos($wp_version, '2.7') !== false || strpos($wp_version, '2.8') !== false || strpos($wp_version, '2.9') !== false ) {

即解决方法:编辑 simple-tags/simple-tags.php

if ( strpos($wp_version, ‘2.7′) !== false || strpos($wp_version, ‘2.8′) !== false) {

修改成:

if ( strpos($wp_version, ‘2.7′) !== false || strpos($wp_version, ‘2.8′) !== false || strpos($wp_version, ‘2.9′) !== false ) {

Post a Comment

Your email is never published nor shared. Required fields are marked *

*

*

Type your comment out: