mirror of
https://framagit.org/framasoft/framadate/funky-framadate-front.git
synced 2023-08-25 13:53:14 +02:00
20 lines
644 B
JavaScript
20 lines
644 B
JavaScript
window.onload = () => {
|
|
var monStockage = localStorage;
|
|
if(localStorage.getItem('type_sondage') == undefined) {
|
|
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'))
|
|
})
|
|
}
|
|
|