Posted By

shamrog12 on 07/09/06


Tagged


Versions (?)

Who likes this?

6 people have marked this snippet as a favorite

luman
1man
panatlantica
Ernstladen
vali29
skywalker


PHP Random Image


 / Published in: PHP
 

  1. <?php
  2.     $images=array('0.jpg','1.jpg','2.jpg');
  3.     $image=$images[array_rand($images)];
  4.     echo '<img src="path/to/'.$image.'" alt="Image: '.$image.'" />';
  5. ?>

Report this snippet  

You need to login to post a comment.