Search This Blog

triple Equals or === in php

<?php

echo "<b>compare both outputs</b><br><br>";
if(1=='1')
echo "equal";

//for new line
echo '<br>';

if(1==='1')
    echo "equal";
else
    echo "not equal";

?>

output :

compare both outputs

equal
not equal

Share Links

Related Posts Plugin for WordPress, Blogger...