diff options
author | Adam Stück <adam@adast.dk> | 2023-05-22 17:31:07 +0200 |
---|---|---|
committer | Adam Stück <adam@adast.dk> | 2023-05-22 17:31:07 +0200 |
commit | 775e69fea981b1cec03cc8206d69abed9b824df5 (patch) | |
tree | b046516be42400c6fedf8334fb6e7dd284fe6c3f /build/js | |
parent | 288c92e992c5569d8e98d6ee8e926398a2f77069 (diff) |
New file structure
index.html
some-post/
--> index.html
Diffstat (limited to 'build/js')
-rw-r--r-- | build/js/showhide.js | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/build/js/showhide.js b/build/js/showhide.js new file mode 100644 index 0000000..afc9c06 --- /dev/null +++ b/build/js/showhide.js @@ -0,0 +1,27 @@ +/* +http://www.tutorialhelpdesk.com/tutorials/web-development/javascript/how-to-show-hide-a-dhtml-div-using-onclick()-event.html +*/ + +function ShowHide(elementId) +{ + var element = document.getElementById(elementId); + if(element.style.display != "block") + { + element.style.display = "block"; + } + else + { + element.style.display = "none"; + } +} +function UpdateText(element) +{ + if(element.innerHTML.indexOf("Hide") == -1) + { + element.innerHTML = "Hide Abstract"; + } + else + { + element.innerHTML = "Abstract"; + } +} |