[DONE] Don't put members gallery inside a request [DONE] Don't put members gallery inside a request
 

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

Main Menu

[DONE] Don't put members gallery inside a request

Started by Rodinou, August 12, 2005, 08:31:16 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Rodinou

Sorry if I put my question here, but I haven't seen where to post ...

I have written a little fonction to call the last albums on my main page (I have dropped CpmFetch :))

Quote
    <?php

$conn = mysql_Connect('localhost','xxxx','xxxx');
mysql_select_db('rbn.cpg11d_albums',$conn);

$sql = 'select aid, title from rbn.cpg11d_albums order by aid desc limit 0, 50';
$req = mysql_query($sql);

while($data = mysql_fetch_assoc($req))
    {
    echo '<a href="http://www.sortons.net/photos/thumbnails.php?album='.$data['aid'].'" onMouseover="ddrivetip(\'Test\', 400)"; onMouseout="hideddrivetip()">'.$data['title'].'</a><br /> ';
    }

?>

I would like to exclude the last MEMBERS albums ... I don't know to do this, in php ... (I begin !)

Nibbler

Add a restriction so that the album's category is less than 10000

Rodinou

héhéhé ... yes yes ... but I BEGIN I don't know how to ... otherwise I don't post here :)

Nibbler

$sql = 'select aid, title from rbn.cpg11d_albums WHERE category < 10000 order by aid desc limit 0, 50';

Rodinou