и снова фотогалерея

А можно вот ненужную верхушку убрать и оставить просто вот так:
<!--c1--><div class='codetop'>Код</div><div class='codemain'><!--ec1--><?php
$result=dbquery(
&nbsp;&nbsp;&nbsp;&nbsp;"SELECT ta.album_id,album_title,photo_id,photo_title,photo_thumb1 FROM ".$db_prefix."photo_albums ta ".
&nbsp;&nbsp;&nbsp;&nbsp;"INNER JOIN ".$db_prefix."photos USING (album_id) ORDER BY RAND() LIMIT 3");
if (dbrows($result) != 0)
{
openside("Фотогалерея");
&nbsp;&nbsp;&nbsp;&nbsp;while ($data = dbarray($result))
&nbsp;&nbsp;&nbsp;&nbsp; {&nbsp;&nbsp; if ($data['photo_thumb1'] && file_exists(PHOTOS."album_".$data['album_id']."/".$data['photo_thumb1'])){
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$rphoto = PHOTOS."album_".$data['album_id']."/".$data['photo_thumb1'];
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;} else {
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$rphoto = IMAGES."imagenotfound.jpg";
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo "<div style='text-align:center'>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href='".BASEDIR."photogallery.php?photo_id=".$data['photo_id']."' class='gallery'>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<img src='".$rphoto."' alt='".$data['photo_title']."' title='".$data['photo_title']."' border='0'>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</a><br />".$data['photo_title']."
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href='".BASEDIR."photogallery.php?album_id=".$data['album_id']."'>".$data['album_title']."</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</div><br />";
&nbsp;&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp;&nbsp;@closeside();&nbsp;&nbsp;
}
?><!--c2--></div><!--ec2-->
 
Сверху