PHP Code:
<?php
$ile = 5;
// I used this line to test it
// $file = array(1,2,3,4,5,6,7,8,9,0);
$file = file('pics.txt');
echo '<table width="600"><tr>';
echo "\n";
srand((double)microtime()*1000000);
$link = array_rand($file, $ile);
for($i=0; $i<$ile; $i++)
{
$sp = explode('||', $link[$i]);
if($sp[0] <> '')
{
echo '<td align=middle>';
echo "\n";
echo '<a href="'.$sp[2].'"><img src="'.$sp[0].'" border=3></a><br>';
echo "\n";
echo '<font style="font-weight: bold; font-size: 11px; font-family: Tahoma">'.$sp[1].'<br></font>';
echo "\n";
echo '</td>';
echo "\n";
}
}
echo '</tr></table>';
echo "\n";
?>
I think that should work.
Edit: Ah, phpkid already replied
