Need to create a list of numbers in random order? Here's a quick and easy way.
<?php
$arrRandom = range(1,7);
shuffle($arrRandom);
?>
First link creates an array with numbers 1 through 7. Second line shuffles the array. Piece of cake, huh?
Ryan
Welcome to the Forums, Blogs, Wikis discussion boards. If you're new here please take a moment to register for an account. If you're already a member here, welcome back. Please login to join in.
Need to create a list of numbers in random order? Here's a quick and easy way.
<?php
$arrRandom = range(1,7);
shuffle($arrRandom);
?>
First link creates an array with numbers 1 through 7. Second line shuffles the array. Piece of cake, huh?
You must log in to post.