Advertisement
Guest User

Untitled

a guest
Jul 27th, 2017
47
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.50 KB | None | 0 0
  1. <?php
  2.                 if ($_POST['zipcode']) {
  3.                     $zipcode = trim($_POST['zipcode']);
  4.                     $zip_length = strlen($zipcode);
  5.                     if ($zip_length != 5) {
  6.                         print "Nem megfelelő számú karakter";
  7.                     }
  8.                     else {
  9.                         print "az irányítószám: $zipcode";
  10.                     }  
  11.                     @h@
  12.                 @h@}
  13.                 @h@else {
  14.                     print <<<_HTML_
  15. <form method="post" action="$_SERVER[PHP_SELF]">
  16. Irányítószám: <input type="text" name="zipcode">
  17. <br/>
  18. <input type="submit" value="Elküld">
  19. </form>
  20. _HTML_;
  21. }
  22.  
  23. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement