How would you compare two values in an array if say your array is:
$numbers = array("1", "2", "3"); and you want to compare the values using an if statement: if($numbers[0]>$numbers[1]) echo "false"; else echo "true";
...and so on.
theknight;10978598 wrote:How would you compare two values in an array if say your array is: $numbers = array("1", "2", "3"); and you want to compare the values using an if statement: if($numbers[0]>$numbers[1]) echo "false"; else echo "true"; ...and so on.
Nevermind, works.
For some reason when I do "== " it doesn't work.