aboutsummaryrefslogtreecommitdiff
path: root/static/js/weabotxt.js
diff options
context:
space:
mode:
Diffstat (limited to 'static/js/weabotxt.js')
-rw-r--r--static/js/weabotxt.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/static/js/weabotxt.js b/static/js/weabotxt.js
index 670ce50..13911da 100644
--- a/static/js/weabotxt.js
+++ b/static/js/weabotxt.js
@@ -211,6 +211,23 @@ document.addEventListener("DOMContentLoaded", function() {
}
}
+ if (screen.width<720) {
+ var head=document.getElementById("main_nav");
+ var b=head.getElementsByTagName("a");
+ var s=document.createElement("select");
+ for(var i=1;i<b.length;i++) {
+ var o = document.createElement("option");
+ o.value = b[i].href;
+ o.textContent = b[i].textContent;
+ if(b[i].className=="cur_brd") o.defaultSelected = true;
+ s.appendChild(o);
+ }
+ s.addEventListener("change", function(e){ window.location.href=this.value; });
+ head.className = "mob fix";
+ head.innerHTML = '<a href="/" target="_top">Bienvenido a Internet</a> | ';
+ head.appendChild(s);
+ }
+
var forms = document.getElementsByTagName("form");
for(var i=0;i<forms.length;i++) { if(forms[i].id.startsWith("postform")) setInputs(forms[i].id); }