Using wp_list_pages() after calling query_posts()

This is for future askers, Whenever you use query_posts or custom wp_query you should add wp_reset_query(); after your loop or when you are done processing your posts. This little line of code will help in solving pagination issues or in your case rest the global $post the original as before your query.

Automatically create a new page daily with last three posts

You can create date.php (you can copy the content for this from archive.php or index.php) in your theme folder which will handle all the “day” pages… <?php get_header(); ?> <div id=”container”> <div id=”content” role=”main”> <?php $day = get_query_var(‘day’); $monthnum = get_query_var(‘monthnum’); $year = get_query_var(‘year’); if ( is_day() ) : ?> <a href=”https://wordpress.stackexchange.com/questions/15424/<?php echo get_day_link($year, $monthnum, … Read more

Display Notification Bar on Header on Certain Post Count

A simple way to achieve this would be to do something like the following; <?php $user_id = get_current_user_id(); $post_count = count_user_posts($user_id); if ($post_count >= 50 && $post_count < 100) { // Congratulations you have submitted 50 posts! } elseif ($post_count >= 100) { // etc etc… } else { // do something else, or nothing. … Read more