PHP MYSQL - Operators - 5.2

 

AssignmentSame as...Description
x = yx = yThe left operand gets set to the value of the expression on the right
x += yx = x + yAddition
x -= yx = x - ySubtraction
x *= yx = x * yMultiplication
x /= yx = x / yDivision
x %= yx = x % yModulus                    
Ex: =
<!DOCTYPE html>
<html>
<body>

<?php
$x = 100;  
echo $x;
?>  

</body>
</html>

Ex: +=
<!DOCTYPE html>
<html>
<body>

<?php
$x = 10;  
$y = 20;

 $x+=$y;
echo $x;

?>  

</body>
</html>

Video

Popular posts from this blog

Install Windows 7 Operating System - Practical

COPA Bits for Computer Based Test (CBT) by Venugopal Vanjarapu

COPA