diff --git a/templates/base.html b/templates/base.html index 468d62e86ee8834009649f4f22baf151eaab9dd8..ca794186cd3300b86fcd738a5b0d095b9eb5098f 100644 --- a/templates/base.html +++ b/templates/base.html @@ -221,6 +221,18 @@ html: true }); }); + $(document).on("click","a.reloadonclose",function () { + var popup = window.open(this.href, this.target); + if (!popup) + return true; + var popup_check = setInterval(function() { + if (popup.closed) { + clearInterval(popup_check); + location.reload(); + }; + }, 500); + return false; + }); </script> </body> </html> diff --git a/templates/lecture.html b/templates/lecture.html index ec88c3e83802a71e5c4bad721cd09380ce7e2590..df6e477ff643a4023147bd8b0552183ad83c242d 100644 --- a/templates/lecture.html +++ b/templates/lecture.html @@ -131,18 +131,6 @@ $(function() { }) }); -$(document).on("click","a.reloadonclose",function () { - var popup = window.open(this.href, this.target); - if (!popup) - return true; - var popup_check = setInterval(function() { - if (popup.closed) { - clearInterval(popup_check); - location.reload(); - }; - }, 500); - return false; -}); $(document).ready(function() { $("a.chapterlink").click(function () {