Title: uladk's Replies | WordPress.org

---

# uladk

  [  ](https://wordpress.org/support/users/uladk/)

 *   [Profile](https://wordpress.org/support/users/uladk/)
 *   [Topics Started](https://wordpress.org/support/users/uladk/topics/)
 *   [Replies Created](https://wordpress.org/support/users/uladk/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/uladk/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/uladk/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/uladk/engagements/)
 *   [Favorites](https://wordpress.org/support/users/uladk/favorites/)

 Search replies:

## Forum Replies Created

Viewing 9 replies - 1 through 9 (of 9 total)

 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Problem: Only one post shown per month in archive](https://wordpress.org/support/topic/problem-only-one-post-shown-per-month-in-archive/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/problem-only-one-post-shown-per-month-in-archive/#post-486908)
 * I made a custom archives.php template that was a combination of `wp_get_archives('
   type=monthly')` and `wp_get_archives('type=postbypost')` so each month also showed
   its ‘postbypost.’
 * The code:
    ` <?php global $month, $wpdb; $now = current_time('mysql'); $arcresults
   = $wpdb->get_results("SELECT DISTINCT YEAR(post_date) AS year, MONTH(post_date)
   AS month, count(ID) as posts FROM " . $wpdb->posts . " WHERE post_date <'" . 
   $now . "' AND post_status='publish' AND post_password='' GROUP BY YEAR(post_date),
   MONTH(post_date) ORDER BY post_date DESC"); if ($arcresults) { foreach ($arcresults
   as $arcresult) { $url = get_month_link($arcresult->year, $arcresult->month); 
   $text = sprintf('%s %d', $month[zeroise($arcresult->month,2)], $arcresult->year);
   echo get_archives_link($url, $text, '','<h5>','</h5>'); $thismonth = zeroise(
   $arcresult->month,2); $thisyear = $arcresult->year; $arcresults2 = $wpdb->get_results("
   SELECT ID, post_date, post_title, post_excerpt, comment_status FROM " . $wpdb-
   >posts . " WHERE post_date LIKE '$thisyear-$thismonth-%' AND post_status='publish'
   AND post_password='' ORDER BY post_date DESC"); if ($arcresults2) { echo"<ul 
   class='arc'>"; foreach ($arcresults2 as $arcresult2) { if ($arcresult2->post_date!
   = '0000-00-00 00:00:00') { $url = get_permalink($arcresult2->ID); $arc_title 
   = $arcresult2->post_title; $excerpt_arc = $arcresult2->post_excerpt; if ($arc_title)
   $text = strip_tags($arc_title); else $text = $arcresult2->ID; echo "<p class='
   trig trigger'>".get_archives_link($url, $text, ''); $comments = mysql_query("
   SELECT * FROM " . $wpdb->comments . " WHERE comment_post_ID=" . $arcresult2->
   ID); $comments_count = mysql_num_rows($comments); if ($arcresult2->comment_status
   == "open" OR $comments_count > 0) echo '&nbsp;['.$comments_count.']'; echo " ";
   echo"<div class='excerpt'>"; echo"$excerpt_arc "; echo"<p class='viewarc' style
   ='text-align: right;'><a href=$url>View article</a> "; echo"</div>"; } } echo"
   </ul>"; } } } ?>
 * The result:
    [http://www.designlegion.com/rave/archives/](http://www.designlegion.com/rave/archives/)
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Problem: Only one post shown per month in archive](https://wordpress.org/support/topic/problem-only-one-post-shown-per-month-in-archive/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/problem-only-one-post-shown-per-month-in-archive/#post-486760)
 * Never mind, fixed it.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Archive index showing both month and post](https://wordpress.org/support/topic/archive-index-showing-both-month-and-post/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/archive-index-showing-both-month-and-post/#post-486280)
 * anyone?
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Index page for Pages](https://wordpress.org/support/topic/index-page-for-pages/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 8 months ago](https://wordpress.org/support/topic/index-page-for-pages/#post-451787)
 * EDIT: [Working index Page](http://www.designlegion.com/linux/?page_id=22)
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Index page for Pages](https://wordpress.org/support/topic/index-page-for-pages/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 8 months ago](https://wordpress.org/support/topic/index-page-for-pages/#post-451769)
 * Thanks for your reply. I found a better solution actually. Here’s what I was 
   wanting to accomplish:
 * [Working index Page](http://www.designlegion.com/linux/?page_id=2)
 * If you rollover the menu on the left (top 2 only work so far) you’ll see each
   Page is pulled into the index with their comments and comment reply field without
   reloading the page.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Showing specific pages with comments in an external page](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 8 months ago](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/#post-451401)
 * That worked mate. Thankyou very much.
 * I did try that before also but I see the problem I had. I have the last part 
   of my loop code in my right menu div tag. Since I wanted the pages displayed 
   in the center column I had started another loop inside the first loop so it was
   invalid!
 * The only problem now is that inserting pages into that one has somehow messed
   with my postdata sections. I don’t see the comment notification anymore
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Showing specific pages with comments in an external page](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 8 months ago](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/#post-451365)
 * I tried that, still the first page displays. Here’s what I have:
 * `
    <?php query_posts('page_id=4'); ?> <?php query_posts('page_id=5'); ?>
 * <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
 * loop code, etc
 * Thanks for you help
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Showing specific pages with comments in an external page](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 8 months ago](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/#post-451286)
 * I’ve been using the query_posts as suggested but cannot pull multiple pages. 
   Here’s the code I’ve used:
    ` <?php query_posts('page_id=1,4,6'); ?>  Only the
   first page displays.
 * Any thoughts?
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Showing specific pages with comments in an external page](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/)
 *  Thread Starter [uladk](https://wordpress.org/support/users/uladk/)
 * (@uladk)
 * [19 years, 8 months ago](https://wordpress.org/support/topic/showing-specific-pages-with-comments-in-an-external-page/#post-451255)
 * Cheers mate! I was going to use wordpress pages as a backup but wasn’t sure how
   to change the left navigation. Now I can do that by creating custom page templates.
   Problem partially solved.
 * What I need to know now is can I have one master page which can pull in all the
   content of other specific pages, with their comments and reply fields. I aim 
   to have each pulled in page as a section that users can comment on. It would 
   be like this [current page](http://www.designlegion.com/linux.php) (roll over
   the left menu) but with comments and a reply field under each section.
 * Thanks!

Viewing 9 replies - 1 through 9 (of 9 total)