van 1 naar 3

Hulp nodig bij een modificaties of op zoek naar een MOD? Bekijk ons archief. Support wordt helaas niet meer verleend.
Forumregels

Sinds 1 januari 2009 wordt phpBB2 niet meer ondersteund.
Onderstaande informatie is verouderd en dient uitsluitend als archief.
phpBB2.0.x
Gesloten
Gebruikersavatar
Gekke_Tok
Berichten: 78
Lid geworden op: 08 mar 2005, 23:32
Locatie: Rotterdam
Contacteer:

van 1 naar 3

Bericht door Gekke_Tok » 26 apr 2006, 15:04

ik ben bezig met een mod voor met random pictures
alleen ben ik er nog niet echt uit hoe ik nou in plaats van 1 random foto 3 random foto's kan laten zien iemand een idee om me te helpen hier is het bestand

<?
$content = "";



$count = $this->stats['tot_gallery'];
$start = rand(0, ($count -1));
$query = $DB->query("SELECT id, titolo, file FROM mkp_gallery where validate = '1' LIMIT $start, 2");
$foto = $DB->fetch_row($query);
$id = $foto['id'];
$titolo = $foto['titolo'];
$file = $foto['file'];
$thumb = "t_$file";


if (!file_exists("$this->sitepath/mkportal/modules/gallery/album/$thumb")) {
$thumb_mes = $this->ResizeImage(120,"$this->sitepath/mkportal/modules/gallery/album/$file");
$content = "
<tr>
<td align=\"center\"><a href=\"$this->siteurl/index.php?ind=gallery&op=foto_show&ida=$id\"><img src=\"$this->siteurl/mkportal/modules/gallery/album/$file\" border=\"0\" width=\"$thumb_mes[0]\" height=\"$thumb_mes[1]\" alt=\"{$this->lang['gallery_zoom']}\" /></a>
</td>
</tr>
<tr>
<td class=\"tdblock\" align=\"center\">$titolo<br />
</td>
</tr>
";
} else {
$content = "
<tr>
<td align=\"center\"><a href=\"$this->siteurl/index.php?ind=gallery&op=foto_show&ida=$id\"><img src=\"$this->siteurl/mkportal/modules/gallery/album/$thumb\" border=\"0\" alt=\"{$this->lang['gallery_zoom']}\" /></a>
</td>
</tr>
<tr>
<td class=\"tdblock\" align=\"center\">$titolo<br />
</td>
</tr>
";
}

if(!$id) {
$content = "
<tr>
<td class=\"tdblock\" align=\"center\">
{$this->lang['no_galleryim']}
</td>
</tr>
";
}

if(!$mkportals->member['g_access_cp'] && !$this->member['g_access_gallery']) {
$content = "
<tr>
<td class=\"tdblock\" align=\"center\">
{$this->lang['gallery_noallow']}
</td>
</tr>
";
}
unset($query);
unset($count);
unset($start);
unset($foto);
unset($id);
unset($titolo);
unset($file);
unset($thumb);



?>
alvast bedankt voor diegene die mij kan helpen met de oplossing zodat er 3 random foto's verschijnen in plaats van 1
~The Reality Is That The Hitman Doesn't Exist, He Is An Illusion, An Entity Wich His Enemies Cannot See Or Touch~

Gesloten