Facebook
From Bitty Rhinoceros, 6 Years ago, written in Plain Text.
This paste is a reply to Untitled from Sweltering Bison - view diff
Embed
Download Paste or View Raw
Hits: 396
  1. <!DOCTYPE html>
  2. <html>
  3. <title>DANIEL KĘPKA</title>
  4. <meta charset="UTF-8">
  5. <head>
  6. <style>
  7. div#góra{
  8. width:100%;
  9. height:250px;
  10. font-size:50px;
  11. float:left;
  12. background-color:red;
  13. }
  14. div#lewo{
  15. width:25%;
  16. height:500px;
  17. float:left;
  18. background-color:green;
  19. }
  20. div#prawo{
  21. width:75%;
  22. height:500px;
  23. float:left;
  24. background-color:yellow;
  25. }
  26. div#dół{
  27. width:100%;
  28. height:225px;
  29. float:left;
  30. background-color:red;
  31. }
  32. </style>
  33.     <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
  34. <script>
  35.     $(document).ready(function () {
  36.         $('#count').click(function () {
  37.             var name = $('#imie').val();
  38.             var lastname = $('#nazwisko').val();
  39.             var c = parseInt($('#c').val());
  40.             var d = parseInt($('#d').val());
  41.             var e = parseInt($('#e').val());
  42.             var f = parseInt($('#f').val());
  43.  
  44.             var result = (c + d + e + f) / 4;
  45.  
  46.             $('#cos').html(result);
  47.         });
  48.     });
  49. </script>
  50.  
  51.  
  52.  
  53.  
  54.  
  55. </head>
  56. <body>
  57. <div id="góra" style="text-align: center;">ŚREDNIA</div>
  58. <div id="lewo">
  59. <form name="formularz" action="">
  60. IMIE:<input type="text" id="imie"><br>
  61. NAZWISKO:<input type="text" id="nazwisko"><br>
  62. <b>OCENY</b><br>
  63. WITRYNY:<input type="number" id="c" min="1" max="6"><br>
  64. BAZY DANYCH:<input type="number" id="d" min="1" max="6"><br>
  65. MATEMATYKA:<input type="number" id="e" min="1" max="6"><br>
  66. FIZYKA:<input type="number" id="f" min="1" max="6"><br>
  67. <input type="button" value="OBLICZ" id="count">
  68. </form>
  69. </div>
  70. <div id="prawo">
  71.  
  72.  
  73. <p id="cos">asfsafas</p>
  74.  
  75.  
  76.  
  77.  
  78.  
  79. </div>
  80. <div id="dół"></div>
  81. </body>
  82. </html>