Make WordPress Core

Changeset 365 for trunk/b2calendar.php


Ignore:
Timestamp:
09/10/2003 07:30:08 AM (22 years ago)
Author:
alex_t_king
Message:

added check for post_status to query that sees which days have posts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/b2calendar.php

    r360 r365  
    128128$calendarmonthwithpost = 0;
    129129while($calendarmonthwithpost == 0) {
    130     $arc_sql="SELECT DISTINCT YEAR(post_date), MONTH(post_date), DAYOFMONTH(post_date) AS dom FROM $tableposts WHERE MONTH(post_date) = '$thismonth' AND YEAR(post_date) = '$thisyear' ORDER BY post_date DESC";
     130    $arc_sql="SELECT DISTINCT YEAR(post_date), MONTH(post_date), DAYOFMONTH(post_date) AS dom FROM $tableposts WHERE MONTH(post_date) = '$thismonth' AND YEAR(post_date) = '$thisyear' AND post_status = 'publish' ORDER BY post_date DESC";
    131131    $querycount++;
    132132    $arc_results = $wpdb->get_results($arc_sql);
Note: See TracChangeset for help on using the changeset viewer.