View file wap/rangal.php
<?php
$sql = "SELECT id, uid, imageurl FROM mx_usergallery ORDER BY RAND() LIMIT 5";
$items = mysql_query($sql);
echo mysql_error();
if(mysql_num_rows($items)>0)
{
while ($item = mysql_fetch_array($items))
{
$id = $item[0];
$img = $item[2];
$whonick = getnick_uid($item[1]);
$ext = getext($img);
$foto = "<img src=\"thumb.php?image=$img&w=33&h=33&type=$ext\" alt=\"$whonick\"/>";
echo "$foto";
}
}
?>