-
Notifications
You must be signed in to change notification settings - Fork 0
/
ofi.js
60 lines (41 loc) · 1.37 KB
/
ofi.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
var coll = document.getElementById("franja");
var nom = document.getElementById("titulo");
var cont = document.getElementById("contenido");
coll.addEventListener("click", abrir);
function abrir() {
if (cont.style.display === "none") {
cont.style.display = "block";
nom.innerHTML = "Contenidos ▲";
} else {
cont.style.display = "none";
nom.innerHTML = "Contenidos ▼";
}
}
var menutitle = document.getElementById("menu");
var langtitle = document.getElementById("lang");
var menucont = document.getElementById("menucont");
var langcont = document.getElementById("langcont");
menutitle.addEventListener("click", menu);
function menu() {
if (menucont.style.display === "none") {
menucont.style.display = "block";
langcont.style.display = "none";
langtitle.innerHTML = "Cast ▼";
menutitle.innerHTML = "Menu ▲";
} else {
menucont.style.display = "none";
menutitle.innerHTML = "Menu ▼";
}
}
langtitle.addEventListener("click", lang);
function lang() {
if (langcont.style.display === "none") {
langcont.style.display = "block";
langtitle.innerHTML = "Cast ▲"
menucont.style.display = "none";
menutitle.innerHTML = "Menu ▼";
} else {
langcont.style.display = "none";
langtitle.innerHTML = "Cast ▼";
}
}