35 lines
931 B
HTML
Executable file
35 lines
931 B
HTML
Executable file
<!DOCTYPE html>
|
|
<html>
|
|
<title>Exercici 01</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
|
|
<head>
|
|
<script>
|
|
window.addEventListener("load", main);
|
|
function main() {
|
|
document.getElementById("webs").addEventListener("change", function(){
|
|
window.open(this.value);
|
|
// alert(this.value);
|
|
// alert("holaa");
|
|
})
|
|
}
|
|
|
|
</script>
|
|
</head>
|
|
<body>
|
|
|
|
<div class="w3-container">
|
|
<h1>Exercici 01</h1>
|
|
</div>
|
|
|
|
<div class="w3-container">
|
|
<select name="webs" id="webs">
|
|
<option value="https://hetzner.com" class="w3-button w3-black">Hetzner</option>
|
|
<option value="https://512kb.club" class="w3-button w3-black">512KB Club</option>
|
|
<option value="https://w3schools.com" class="w3-button w3-black">W3 Schools</option>
|
|
</select>
|
|
</div>
|
|
|
|
</body>
|
|
</html>
|