Witam, chciałem w swojej galerii zrobić losowe wyświetlanie zdjęć. Nie wiem w którym miejscu wkleić php do html żeby działało :/
to są kody:
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-5" /> <link rel="stylesheet" type="text/css" href="style2.css" />
<table width="100%" cellpadding="0" cellspacing="0" style="height:100%"> <td class="left"><img src="images/spacer.gif" width="1" height="1" alt="" /></td> <p style="cursor:crosshair;"><img src="images/logo.gif" alt="" width="700" height="180" class="float" /></p> <a target="_blank" href="art/CCI_00000.jpg"><img src="art/CCI_00000.jpg" alt="Girl" width="57" height="78" /></a> <a target="_blank" href="art/CCI_00001.jpg"><img src="art/CCI_00001.jpg" alt="Girl" width="57" height="78" /></a> <a target="_blank" href="art/CCI_00002.jpg"><img src="art/CCI_00002.jpg" alt="Girl" width="57" height="78" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <a target="_blank" href="#"><img src="" alt="" width="57" height="57" /></a> <td class="right"><img src="images/spacer.gif" width="1" height="1" alt="" /></td>
<?php
$dir = './images/';
$exts = array( 'gif', 'jpg', 'jpeg', 'png', 'JPG', 'JPEG', 'GIF', 'PNG' ); {
{
{
$imgs[] = $f;
}
}
}
echo '<img src="' . $dir . $img . '"/>';
?>
Chodzi mi o to aby losowe zdjęcie pokazywało się po lewej stronie galerii.
Tu jest stronka testowa
http://mist-sn.ugu.pl/galery.html