Upload files to "/"

This commit is contained in:
5803025024 2025-11-17 02:35:02 -05:00
commit 9c30b00080

34
week 7.html Normal file
View File

@ -0,0 +1,34 @@
<html>
<head>
<script>
function tampilkan()
{
var nama = document.getElementById("nama").values;
var umur = document.getElementById("umur").value;
document.write(nama);
var Hobi = document.getElementByName("hobi");
for (let i=0;i<Hobi.length;i++)
{
if (Hobi(i).hasAttribute("checked")==true)
document.write(Hobi[1].value);
}
}
</script>
</head>
<body>
<form method="GET" action="hal.html">
Nama : <input type="text" name="nama" id="nama"><br>
Umur : <input type="number" name="umur" id="umur"><br>
Alamat: <input type="text"><br>
Hobi : <input type="checkbox" name="Hobi" value="Baca">Baca
<input type="checkbox" name="Hobi" value="Makan">Makan
<input type="checkbox" name="Hobi" value="Tidur">Tidur
<br><input type="submit" value="kirim dengan GET-Submit">
<!--<input type="button" value="kirim dengan GET-Button" onclick="window.location.href='hal2.html'">-->
<input type="button" value="kirim dengan GET-Button" onclick="tampilkan()">
</form>
</body>
</html>