Randomizer

Posted under » PHP » Python on 22 March 2012

You can do this thru array_rand command.

$ad_row1 = array(
   1 => array('url' => 'http://heh.edu.sg/', 'img' => 'webtools_depth.jpg'),
   2 => array('url' => 'http://hoi.edu.sg/', 'img' => 'webtools_click.jpg'),
  ); 

$ad1 = array_rand($ad_row1);

echo '

click here

';

For python, you can try this.

web security linux ubuntu python django git Raspberry apache mysql php drupal cake javascript css AWS data