From fa0753801a76cbbb4850e4c02def3a9c23950158 Mon Sep 17 00:00:00 2001 From: saxmatt Date: Sat, 12 Feb 2005 05:25:09 +0000 Subject: [PATCH] Don't show pages or objects in recent posts. git-svn-id: http://svn.automattic.com/wordpress/trunk@2281 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/functions-post.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-includes/functions-post.php b/wp-includes/functions-post.php index e9edea2b4a..737fe19931 100644 --- a/wp-includes/functions-post.php +++ b/wp-includes/functions-post.php @@ -84,7 +84,7 @@ function wp_get_recent_posts($num = 10) { $limit = "LIMIT $num"; } - $sql = "SELECT * FROM $wpdb->posts ORDER BY post_date DESC $limit"; + $sql = "SELECT * FROM $wpdb->posts WHERE post_status IN ('publish', 'draft', 'private') ORDER BY post_date DESC $limit"; $result = $wpdb->get_results($sql,ARRAY_A); return $result?$result:array();