uDesign
  1. <?php
  2. if (isset($_POST['ok'])) {
  3. $a = isset($_POST['a']) ? abs($_POST['a']) : false;
  4. $b = isset($_POST['b']) ? abs($_POST['b']) : false;
  5.  
  6. echo 'Natija:' . $a + $b;
  7. }
  8. ?>
  9.  
  10. <form method="post">
  11. <input type="text" name="a"><br>
  12. <input type="text" name="b"><br>
  13. <input type="submit" name="ok" value="Qo'shish">
  14. </form>