]> git.wh0rd.org Git - tt-rss.git/commitdiff
use CDN for scriptaculous
authorMike Frysinger <vapier@gmail.com>
Thu, 30 May 2013 06:36:54 +0000 (02:36 -0400)
committerMike Frysinger <vapier@gmail.com>
Mon, 10 Dec 2018 01:18:39 +0000 (20:18 -0500)
index.php

index 3b0962f02e20cac66cace1d782672757ce14852b..9be7d5ccc35f25197911e50b289cbafe7ce31f12 100644 (file)
--- a/index.php
+++ b/index.php
 
        <?php
        foreach (array("lib/prototype.js",
-                               "lib/scriptaculous/scriptaculous.js?load=effects,controls",
+                               "//ajax.googleapis.com/ajax/libs/scriptaculous/1.8.3/scriptaculous.js?load=effects,controls",
+                               // "//ajax.googleapis.com/ajax/libs/dojo/1.8.3/dojo/dojo.js",
                                "lib/dojo/dojo.js",
                                "lib/dojo/tt-rss-layer.js",
                                "errors.php?mode=js") as $jsfile) {
 
+               if ($jsfile == "klib/dojo/dojo.js") {?>
+       <script data-dojo-config="async: 1, dojoBlankHtmlUrl: '/lib/dojo/resources/blank.html',
+                       packages: [ {
+                               name: 'custom',
+                               location: location.pathname.replace(/\/[^/]+$/, '') + '/js/custom'
+                       } ]"
+               src="//ajax.googleapis.com/ajax/libs/dojo/1.8.3/dojo/dojo.js"></script>
+               <?} else
+
                echo javascript_tag($jsfile);
 
        } ?>