1// You cannot compare float values like you would compare intergers in PHP
2// since a float is calculated and may not have the exact value as shown
3// an easy way to get around this is to round the float, then convert the float
4//to a string for the comparison
5$a = 1.5;
6$b = 1.5;
7$a = round($a, 2);
8$b = round($b, 2);
9if (strval($a) === strval($b)) var_dump('it matches!');