Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="pl">
- <head>
- <meta charset="UTF-8" >
- <title> suma liczb</title>
- <style>
- body{background-color:blue;
- color: white;
- font-size:1.5em;
- }
- input{
- height:20px;
- margin:6px;
- }
- </style>
- </head>
- <body>
- <h1>Suma liczb</h1>
- <form>
- Podaj pierwszą liczbę: <input id="liczba1" autofocus type="text" ><br> Podaj drugą liczbę:<input id="liczba2" type="text" ><br>
- <input type="button" onclick="obliczSume()" value="oblicz sumę "><input id="suma" type="text" disabled> <input type="reset" value="wyczysc pola">
- </form>
- <script>
- function obliczSume(){
- var n1=parseInt(document.getElementById("liczba1").value);
- var n2=parseInt(document.getElementById("liczba2").value); document.getElementById("suma").value=n1+n2;
- }
- </script>
- </body>
- </html>
- 12 minutes ago · Sent from Web
- Adrian Bernatek
- zad4
- 12 minutes ago · Sent from Web
- Adrian Bernatek
- <head>
- <meta http-equiv="Content-type" content="text/html; Windows-1250"/> <meta name="lang" content="pl"/>
- </head>
- <body>
- <h2>Podaj imię</h1>
- <hr/>
- <form action="" method="GET">
- <label>Podaj imię:<br/>
- <input type="text" name="imie"/>
- </label> <label>Nazwisko: <input type="text" name="nazwisko"/> </label>
- <button type="submit">Wyślij</button>
- </form>
- </body>
- </html>
- Just now · Sent from Web
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement