Check Teer Result

How to create a simple calculator using PHP

How to create a simple calculator using PHP 


So we will learn on this session, how to create a simple calculator on PHP 

<?php
  if(isset($_POST['submit'])){
 $num1 = $_POST['number1'];
 $num2 = $_POST['number2'];
 
 $result = $num1 + $num2;
 
 echo "<center><h2>$num1 + $num2 = $result</h2></center>";
  }



?>
<form method="post" action="calcu.php" enctype="multipart/form-data">
   Enter Numer One : <input type="text" name="number1"/><br>
   Enter Numer two : <input type="text" name="number2"/><br>
   <input type="submit" name="submit"/>
</form>

Now we will learn the above code with video tutorial :- 





EmoticonEmoticon