Changeset 2424 for trunk/include/section_init.inc.php
- Timestamp:
- Jul 6, 2008, 12:13:28 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/section_init.inc.php
r2327 r2424 236 236 { // get all allowed sub-categories 237 237 $query = ' 238 SELECT id 238 SELECT id 239 239 FROM '.CATEGORIES_TABLE.' 240 WHERE 240 WHERE 241 241 uppercats LIKE "'.$page['category']['uppercats'].',%" ' 242 242 .get_sql_condition_FandF( … … 395 395 else if ($page['section'] == 'recent_pics') 396 396 { 397 if ( !isset($page['super_order_by']) ) 398 { 399 $conf['order_by'] = str_replace( 400 'ORDER BY ', 401 'ORDER BY date_available DESC,', 402 $conf['order_by'] 403 ); 404 } 405 397 406 $query = ' 398 407 SELECT DISTINCT(id) … … 524 533 WHERE file LIKE "' . $page['image_file'] . '.%" ESCAPE "|"'; 525 534 if ( count($page['items']) < 500) 526 {// for very large item sets do not add IN - because slow 535 {// for very large item sets do not add IN - because slow 527 536 $query .= ' 528 537 AND id IN ('.implode(',',$page['items']).') … … 534 543 case 0: break; 535 544 case 1: 536 list($page['image_id'], $page['image_file']) = mysql_fetch_row($result); 545 list($page['image_id'], $page['image_file']) = mysql_fetch_row($result); 537 546 break; 538 547 default: // more than 1 file name match
Note: See TracChangeset
for help on using the changeset viewer.