I want to display two Divs from an array at random without the same Div displaying twice.
This is what I've been using to display 1 Div at random
<?
$divs = array('<div id="divFirst">First Div</div>','<div id="divFirst">Second Div</div>','<div id="divFirst">Third Div</div>','<div id="divFirst">Fourth Div</div>');
shuffle($divs);
print array_shift($divs);
?>
I need to generate a unique pair of random numbers in PHP, Then I should be able to figure out how to make two divs in an array display.
I've searched for this question a lot. And while there are many questions on random non repeating numbers I can't find one for PHP, that doesn't use jQuery, SQL, Javascript or works on modern versions of PHP