diff options
author | Bojan Suzic <bojan.suzic@iaik.tugraz.at> | 2014-01-27 17:42:51 +0100 |
---|---|---|
committer | Bojan Suzic <bojan.suzic@iaik.tugraz.at> | 2014-01-27 17:42:51 +0100 |
commit | aba2defe8f95cf960395158f6eb2ad7b1fb6e150 (patch) | |
tree | 298a0165a30b8538b89abb93a399c615f91702d3 /id/oa/src/main/webapp/js | |
parent | ed9ad9b0c13ee0de3231bab038f35b01beeb0d0b (diff) | |
parent | cea2f395ec773b386ec628d60120752cf320f6b6 (diff) | |
download | moa-id-spss-aba2defe8f95cf960395158f6eb2ad7b1fb6e150.tar.gz moa-id-spss-aba2defe8f95cf960395158f6eb2ad7b1fb6e150.tar.bz2 moa-id-spss-aba2defe8f95cf960395158f6eb2ad7b1fb6e150.zip |
merging
Diffstat (limited to 'id/oa/src/main/webapp/js')
-rw-r--r-- | id/oa/src/main/webapp/js/common.js | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/id/oa/src/main/webapp/js/common.js b/id/oa/src/main/webapp/js/common.js new file mode 100644 index 000000000..59b7b4e0e --- /dev/null +++ b/id/oa/src/main/webapp/js/common.js @@ -0,0 +1,32 @@ +function gup(name) { + name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]"); + var regexS = "[\\?&]"+name+"=([^&#]*)"; + var regex = new RegExp( regexS ); + var results = regex.exec( window.location.href ); + if( results == null ) + return ""; + else + return results[1]; +} +function jumpToAnker() { + var jump = gup("jump"); + if (jump != "") { + location.hash="#"+jump; + } +} +function PVP2LoginIframe(url) { + var el = document.getElementById("demonstrator_leftcontent"); + + var iframe = document.createElement("iframe"); + iframe.setAttribute("src", url); + iframe.setAttribute("width", "240"); + iframe.setAttribute("height", "220"); + iframe.setAttribute("frameborder", "0"); + iframe.setAttribute("scrolling", "no"); + iframe.setAttribute("title", "Login"); + + var button = document.getElementById("submitbutton"); + button.parentNode.removeChild(button); + + el.appendChild(iframe, el); +} |