2013-09-16 24 views
0

假设2个不同的贡献者提交了2个不同的帖子用于管理员审查,我们可以找出哪个贡献者推送了哪个帖子进行审阅?WordPress的:哪个用户提交的文章审查?

如果是这样,那么这些信息存储在数据库中?

实际上,我想列出特定贡献者“提交审阅”的所有帖子。

+0

wp_posts' – Joren

+0

你是否使用了外挂什么的? – Hackerman

+0

@Joren在哪个列下? post_author, POST_DATE, post_date_gmt, POST_CONTENT, POST_TITLE, post_excerpt, post_status, comment_status, ping_status, post_password, POST_NAME, to_ping, 执行ping操作, post_modified, post_modified_gmt, post_content_filtered, post_parent, guid, menu_order, post_type, post_mime_type, comment_count, – Rao

回答

1

wp_postmeta表中,有一个名为_edit_last的条目,它给出了给定帖子的最后编辑用户的ID。如果你想返回所有待处理的讯息对于一个给定作者ID,无论作者的查询,你可以使用这样的事情:

$params = array(
'post_status' => 'pending', 
'meta_key' => '_edit_last', 
'meta_value' => user_id 
); //Change user_id to the author's ID 

$pending_posts_edited = new WP_Query($params); 
while($pending_posts_edited->have_posts()) : $pending_posts_edited->the_post(); ?> 

//Loop as you normally would 

<?php endwhile; ?> 
表中的`