diff options
author | Simon Rettberg | 2019-05-29 13:30:54 +0200 |
---|---|---|
committer | Simon Rettberg | 2019-05-29 13:30:54 +0200 |
commit | fabe31aa314d1549193e87ef149b89b20fcc6b14 (patch) | |
tree | 750e3faefc9a6d38e3df7d5876a1359029502d5f /script | |
parent | [news] Modularize; add 'login-news' category (diff) | |
download | slx-admin-fabe31aa314d1549193e87ef149b89b20fcc6b14.tar.gz slx-admin-fabe31aa314d1549193e87ef149b89b20fcc6b14.tar.xz slx-admin-fabe31aa314d1549193e87ef149b89b20fcc6b14.zip |
[exams/bootstrap_datepicker] Always load slx-admin language plugin
Fixes #3567
Diffstat (limited to 'script')
-rw-r--r-- | script/slx-fixes.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/script/slx-fixes.js b/script/slx-fixes.js index 06453ca0..be35f56b 100644 --- a/script/slx-fixes.js +++ b/script/slx-fixes.js @@ -106,3 +106,13 @@ $(document).ready(function() { } slxCheckCallbacks(); }); + +// Caching script fetcher (https://api.jquery.com/jQuery.getScript/); use exactly like $.getScript +jQuery.cachedScript = function(url, options) { + options = $.extend( options || {}, { + dataType: "script", + cache: true, + url: url + }); + return jQuery.ajax( options ); +}; |