Changeset 2560 for trunk/admin/include/functions.php
- Timestamp:
- Sep 21, 2008, 1:06:20 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/include/functions.php
r2551 r2560 799 799 WHERE dir IS NOT NULL 800 800 ;'; 801 $result = pwg_query($query); 802 $cat_dirs = array(); 803 while ($row = mysql_fetch_array($result)) 804 { 805 $cat_dirs[$row['id']] = $row['dir']; 806 } 801 $cat_dirs = simple_hash_from_query($query, 'id', 'dir'); 807 802 808 803 // caching galleries_url … … 811 806 FROM '.SITES_TABLE.' 812 807 ;'; 813 $result = pwg_query($query); 814 $galleries_url = array(); 815 while ($row = mysql_fetch_array($result)) 816 { 817 $galleries_url[$row['id']] = $row['galleries_url']; 818 } 808 $galleries_url = simple_hash_from_query($query, 'id', 'galleries_url'); 819 809 820 810 // categories : id, site_id, uppercats … … 824 814 SELECT id, uppercats, site_id 825 815 FROM '.CATEGORIES_TABLE.' 826 WHERE id IN ( 816 WHERE dir IS NOT NULL 817 AND id IN ( 827 818 '.wordwrap(implode(', ', $cat_ids), 80, "\n").') 828 819 ;';
Note: See TracChangeset
for help on using the changeset viewer.