Changeset 1069 for trunk/include/calendar_monthly.class.php
- Timestamp:
- Mar 8, 2006, 4:22:25 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/calendar_monthly.class.php
r1063 r1069 140 140 } 141 141 $res = ''; 142 if (isset($date[CYEAR]) and $date[CYEAR]!= 'any')142 if (isset($date[CYEAR]) and $date[CYEAR]!=='any') 143 143 { 144 144 $b = $date[CYEAR] . '-'; 145 145 $e = $date[CYEAR] . '-'; 146 if (isset($date[CMONTH]) and $date[CMONTH]!= 'any')146 if (isset($date[CMONTH]) and $date[CMONTH]!=='any') 147 147 { 148 148 $b .= $date[CMONTH] . '-'; 149 149 $e .= $date[CMONTH] . '-'; 150 if (isset($date[CDAY]) and $date[CDAY]!= 'any')150 if (isset($date[CDAY]) and $date[CDAY]!=='any') 151 151 { 152 152 $b .= $date[CDAY]; … … 163 163 $b .= '01-01'; 164 164 $e .= '12-31'; 165 if (isset($date[CMONTH]) and $date[CMONTH]!= 'any')165 if (isset($date[CMONTH]) and $date[CMONTH]!=='any') 166 166 { 167 167 $res .= ' AND '.$this->calendar_levels[CMONTH]['sql'].'='.$date[CMONTH]; 168 168 } 169 if (isset($date[CDAY]) and $date[CDAY]!= 'any')169 if (isset($date[CDAY]) and $date[CDAY]!=='any') 170 170 { 171 171 $res .= ' AND '.$this->calendar_levels[CDAY]['sql'].'='.$date[CDAY]; … … 177 177 { 178 178 $res = ' AND '.$this->date_field.' IS NOT NULL'; 179 if (isset($date[CMONTH]) and $date[CMONTH]!= 'any')179 if (isset($date[CMONTH]) and $date[CMONTH]!=='any') 180 180 { 181 181 $res .= ' AND '.$this->calendar_levels[CMONTH]['sql'].'='.$date[CMONTH]; 182 182 } 183 if (isset($date[CDAY]) and $date[CDAY]!= 'any')183 if (isset($date[CDAY]) and $date[CDAY]!=='any') 184 184 { 185 185 $res .= ' AND '.$this->calendar_levels[CDAY]['sql'].'='.$date[CDAY]; … … 225 225 $query.= $this->get_date_where(); 226 226 $query.= ' 227 GROUP BY period'; 227 GROUP BY period 228 ORDER BY YEAR('.$this->date_field.') DESC'; 228 229 229 230 $result = pwg_query($query); … … 291 292 $items[$m]['nb_images'] += $row['count']; 292 293 } 293 //echo ('<pre>'. var_export($items, true) . '</pre>');294 294 if (count($items)==1) 295 295 { // only one month exists so bail out to month view
Note: See TracChangeset
for help on using the changeset viewer.