批量删除wordpress某个分类下的所有文章

进入phpmysql 数据库后台,执行以下语句:

delete
from
wp_posts
using
wp_posts,
wp_term_relationships,
wp_term_taxonomy
where
wp_posts.id = wp_term_relationships.object_id
and
wp_term_relationships.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id
and
wp_term_relationships.term_taxonomy_id = 217

id可以变成你的分类的id

发表评论

您的电子邮箱地址不会被公开。