funky-framadate-front/public/parametres.html
2018-09-26 23:05:55 +02:00

64 lines
1.6 KiB
HTML

<!doctype html>
<html lang="fr">
<head>
<meta charset="utf-8">
<meta name="referrer" content="same-origin">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Framadate</title>
<meta name="description" content=" ">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link crossorigin="anonymous" rel="stylesheet" href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<section>
<p>
Je m'appelle
<input name="nom" />
et le titre de ce sondage
<select id="type_sondage">
<option>classique</option>
<option>special dates</option>
</select>
est
<input name="titre" />.
</p>
<p>
Si je devais le décrire pour les autres personnes, je dirais
<textarea></textarea>
</p>
</section>
<nav>
<a href="reponses.html" class="btn" id="next">Continuer</a>
</nav>
<script>
window.onload = () => {
var monStockage = localStorage;
localStorage.setItem('type_sondage', 'classique');
document.querySelector('#type_sondage').addEventListener('change', function() {
const selectedType = this.options[this.selectedIndex].text;
localStorage.setItem('type_sondage', type_sondage);
console.log(selectedType);
if(selectedType == "classique") {
document.querySelector('#next').href = "reponses.html";
} else {
document.querySelector('#next').href = "dates.html";
}
console.log(document.querySelector('#next'))
})
}
</script>
</body>
</html>