Verfasst: 14.11.2006 17:47
Hi, wie ist es möglich Bilder nur von einer bestimmten Kategorie anzeigen zu lassen?
phpBB.de - Die deutsche phpBB-Community
https://www.phpbb.de/community/
Code: Alles auswählen
// Random Pic
$sql = "SELECT *
FROM " . ALBUM_TABLE . " AS a, " . ALBUM_CAT_TABLE . " AS c
WHERE c.cat_id = a.pic_cat_id
AND c.cat_view_level = -1
ORDER BY RAND() LIMIT 1";
if (!$result = $db->sql_query($sql))
{
message_die(GENERAL_ERROR, 'Could not query album information', '', __LINE__, __FILE__, $sql);
}
$randpicrow = $db->sql_fetchrow($result);
// Mighty Gorgon - Full Album Pack - END
Code: Alles auswählen
c.cat_id = a.pic_cat_id
Vielen Dankphillip hat geschrieben:nimm mal dasraus.Code: Alles auswählen
c.cat_id = a.pic_cat_id
Code: Alles auswählen
c.cat_id