You know what are the differences between the control structure in Javascript and control structure in PHP? Both use the if / else, for or while, but that vary in that change?
Are two different programming languages but there are differences in the part of "control structure" in the syntax although both are similar.
Examples
Javascript control structure
<script type="text/javascript">
var a = 5;
var b = 8;
if (a < b)
{
alert(a +" is smaller than " +b);
}
</script>
PHP control structure
<?php
// Number comparison
$a = 5;
$b = 8;
if ($a < $b)
{
echo $a ."is smaller than" .$b;
}
// Result : 5 is smaller than 8
?>
Thanks