Comparing value in if statement == error

#1

I seem to have found an error where leading zeros in value $So1 are ignored with integers values

<?php
$o1 = "0019";
$o2 = "19";
if ($o1 == $o2) {
  echo("== returns true<br>"); // Returns true for above values
}
if ($o1 === $o2) {
  echo("=== returns true<br>");
}
?>

I this just me or an actual php bug

#2

PHP is mostly untyped.