Changeset 587 for trunk/include/functions_category.inc.php
- Timestamp:
- Oct 30, 2004, 5:42:29 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/functions_category.inc.php
r579 r587 89 89 $query = 'SELECT id'; 90 90 $query.= ' FROM '.CATEGORIES_TABLE.' WHERE id = '.$cat.';'; 91 $result = mysql_query( $query );91 $result = pwg_query( $query ); 92 92 if ( mysql_num_rows( $result ) != 0 ) 93 93 { … … 140 140 141 141 $plain_structure = array(); 142 $result = mysql_query( $query );142 $result = pwg_query( $query ); 143 143 while ( $row = mysql_fetch_array( $result ) ) 144 144 { … … 271 271 // ;'; 272 272 273 $row = mysql_fetch_array( mysql_query( $query ) );273 $row = mysql_fetch_array( pwg_query( $query ) ); 274 274 275 275 if ( !isset( $row['total'] ) ) $row['total'] = 0; … … 307 307 $query.= ' AND a.site_id = b.id'; 308 308 $query.= ';'; 309 $row = mysql_fetch_array( mysql_query( $query ) );309 $row = mysql_fetch_array( pwg_query( $query ) ); 310 310 311 311 $cat = array(); … … 330 330 $query.= ' ORDER BY id ASC'; 331 331 $query.= ';'; 332 $result = mysql_query( $query );332 $result = pwg_query( $query ); 333 333 while( $row = mysql_fetch_array( $result ) ) 334 334 { … … 369 369 $query.= ' FROM '.CATEGORIES_TABLE.' WHERE id = '.$category_id; 370 370 $query.= ';'; 371 $row = mysql_fetch_array( mysql_query( $query ) );371 $row = mysql_fetch_array( pwg_query( $query ) ); 372 372 $uppercats = $row['uppercats']; 373 373 } … … 379 379 $query.= ' FROM '.CATEGORIES_TABLE.' WHERE id IN ('.$uppercats.')'; 380 380 $query.= ';'; 381 $result = mysql_query( $query );381 $result = pwg_query( $query ); 382 382 while( $row = mysql_fetch_array( $result ) ) 383 383 { … … 404 404 AND c.id = '.$category_id.' 405 405 ;'; 406 $row = mysql_fetch_array( mysql_query($query));406 $row = mysql_fetch_array(pwg_query($query)); 407 407 return $row['galleries_url']; 408 408 } … … 594 594 WHERE '.implode(' OR ', $search_cat_clauses).' 595 595 ;'; 596 $result = mysql_query($query);596 $result = pwg_query($query); 597 597 $cat_ids = array(); 598 598 while ($row = mysql_fetch_array($result)) … … 669 669 { 670 670 $page['title'] = $conf['top_number'].' '.$lang['most_visited_cat']; 671 672 if ( isset( $forbidden ) ) $page['where'] = ' WHERE '.$forbidden; 673 else $page['where'] = ''; 671 672 $page['where'] = 'WHERE hit > 0'; 673 if (isset($forbidden)) 674 { 675 $page['where'] = "\n".' AND '.$forbidden; 676 } 677 674 678 $conf['order_by'] = ' ORDER BY hit DESC, file ASC'; 675 679 $page['cat_nb_images'] = $conf['top_number']; … … 750 754 '.$page['where'].' 751 755 ;'; 752 $row = mysql_fetch_array( mysql_query($query));756 $row = mysql_fetch_array(pwg_query($query)); 753 757 if ($row['count'] < $conf['top_number']) 754 758 { … … 789 793 if (isset($query)) 790 794 { 791 $result = mysql_query( $query );795 $result = pwg_query( $query ); 792 796 $row = mysql_fetch_array( $result ); 793 797 $page['cat_nb_images'] = $row['nb_total_images']; … … 844 848 $query.= ';'; 845 849 846 $result = mysql_query( $query );850 $result = pwg_query( $query ); 847 851 while ( $row = mysql_fetch_array( $result ) ) 848 852 { … … 875 879 $query.= ' ORDER BY RAND()'; 876 880 $query.= ';'; 877 $result = mysql_query( $query );881 $result = pwg_query( $query ); 878 882 while ( $row = mysql_fetch_array( $result ) ) 879 883 { … … 883 887 } 884 888 } 885 $result = mysql_query( $query );889 $result = pwg_query( $query ); 886 890 while ( $row = mysql_fetch_array( $result ) ) 887 891 {
Note: See TracChangeset
for help on using the changeset viewer.