Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: When disabeling query that fetch album stats i loose all the "album thumbnails"  (Read 2357 times)

0 Members and 1 Guest are viewing this topic.

dke

  • Guest

hi all,

i had a thread going last night about optimizing my index.php loadtime, all seemed fine when i disabeled the code

$sql = "SELECT a.aid, count( p.pid )  AS pic_count, max( p.pid )  AS last_pid, max( p.ctime )  AS last_upload, a.keyword" .
            " FROM {$CONFIG['TABLE_ALBUMS']} AS a " .
            " LEFT JOIN {$CONFIG['TABLE_PICTURES']} AS p ON a.aid = p.aid AND p.approved =  'YES' ".
            "WHERE a.aid IN $album_set" . "GROUP BY a.aid";
    $alb_stats_q = cpg_db_query($sql);
    $alb_stats = cpg_db_fetch_rowset($alb_stats_q);
    mysql_free_result($alb_stats_q);


in index.php, but now i notice that all my thumbnails for my albums are gone, and if i try modify the album and putting a static thumbnail insted of "last upload" they still wont show! Is there a way to modify the code above to remove the statistics (which apparently is lagging the page) but keep the code that is required for the album thumbnails to work (static or last upload dosnt matter, just that one of them work would be awesome)

thanks in advance guys
« Last Edit: July 18, 2006, 12:03:16 am by GauGau »
Logged

Nibbler

  • Guest

Stop making multiple threads just to get attention. Locking.
Logged
Pages: [1]   Go Up
 

Page created in 0.016 seconds with 17 queries.