Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <meta charset="utf-8">
- </head>
- <body>
- <h2>Geben Sie eine zufällige Jahreszahl an:</h2>
- <form action="" method="post">
- <p><input type="text" name="jahr"/>
- <input type="submit" name="submit"/></p>
- </form>
- </body>
- </html>
- <?php
- if(isset($_POST['submit'])){
- if($_POST["jahr"] %4 == 0) {
- echo "<p> Zahl ist teilbar </p>";
- } else {
- echo "<p> Zahl nicht teilbar </p>";
- }
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement