WordPress功能很好很强大,但有些功能过于强大,比如说“日志修订版本管理”功能,对于大多说的blogger来说是用不到的吧。

不管怎么说,反正我是用不到,那么就禁用它吧!

禁用方法:

1.找到wp-config.php文件,在其中加入以下代码

define(‘WP_POST_’, false);

2.找到”wp-settings.php”这个文件, 搜索到这段代码

$default_constants = array( ‘WP_POST_REVISIONS’ => true );

把 “true” 改成 “false” 如下:

$default_constants = array( ‘WP_POST_REVISIONS’ => false );

但对于WordPress 已有的文章修订版本历史 应该怎么办呢?

如果你安装了 WP-DBManager 这个插件,可以到后台点击 Run SQL Query

db-qu

在输入框里,输入sql语句 :

DELETE FROM wp_posts WHERE post_type = “revision”;

DELETE FROM wp_term_relationships WHERE object_id IN (SELECT id FROM wp_posts WHERE post_type=’revision’);

db-qu2

然后,执行 点击 Run

db-qu3

这样就会删除数据库中 所有“版本历史”的文章。

当然如果没安装 WP-DBManager 你也可以到到数据库中,执行sql语句。

提示:无论使用哪种方法,请先备份你的数据库。

 Leave a Reply

(必须)

(必须)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

 
© 2010 vsnew
Suffusion theme by Sayontan Sinha