<?php#random images example#this is your file$file = "images1.txt";#open the file$fp = file($file);#generate a random numbersrand((double)microtime()*1000000);#get one of the entries in the file$random_image = $fp[array_rand($fp)] and array( 1 => "images/theftz.gif", 2 => "images/athen.gif");#laala#display the entryecho "<img src='$random_image'></img>";if($random_image == $random_image == array[1]) {echo 'Hello Theftz.';} elseif ($random_image == array[2]) {echo 'Hello Athen.';} else {echo 'Something is seriously wrong :D';}?>