Zen Garden Randomizer


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1. <?php
  2. // Small PHP script that displays a random design of CSS Zen Garden
  3. $rand = mt_rand(1, 195);
  4. if ( strlen($rand) == 1 ) { $rand = "00" . $rand; }
  5. elseif ( strlen($rand) == 2 ) { $rand = "0" . $rand; }
  6. header("Location: http://www.csszengarden.com/?cssfile=/$rand/$rand.css");
  7. ?>

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.