projects
/
WP-Themes
/
DiscoverKZOO.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd596df
)
removing drafts from recent posts display
author
Anthony Talarico
<talarico@gaslightmedia.com>
Mon, 15 Feb 2016 13:35:56 +0000
(08:35 -0500)
committer
Anthony Talarico
<talarico@gaslightmedia.com>
Mon, 15 Feb 2016 13:35:56 +0000
(08:35 -0500)
parts/blog-sidebar-r.php
patch
|
blob
|
history
diff --git
a/parts/blog-sidebar-r.php
b/parts/blog-sidebar-r.php
index
3675212
..
b6e435a
100644
(file)
--- a/
parts/blog-sidebar-r.php
+++ b/
parts/blog-sidebar-r.php
@@
-23,7
+23,9
@@
$args = array( 'numberposts' => '5' );
$recent_posts = wp_get_recent_posts( $args );
foreach( $recent_posts as $recent ){
+ if(get_post_status($recent["ID"]) != "draft"){
echo '<li><a href="' . get_permalink($recent["ID"]) . '">' . $recent["post_title"].'</a> </li> ';
+ }
}
?>
</ul>