• Howdy! Welcome to our community of more than 130.000 members devoted to web hosting. This is a great place to get special offers from web hosts and post your own requests or ads. To start posting sign up here. Cheers! /Peo, FreeWebSpace.net
managed wordpress hosting

PHP: shuffle() errors

Christopher

New Member
Code:

PHP:
function random($num=5,$sep="<br><br>",$type="aff")
{
  if($type == "aff")
    shuffle($aff);
  else
    shuffle($affi);
	
  for($i=0; $i<$num; $i++)
  {
    print $type[$i];
	print $sep;
  }
}

It says "Warning: shuffle() expects parameter 1 to be array, null given in..." Parameter 1 is an array!
 
Back
Top