]> git.ipfire.org Git - ipfire.org.git/commitdiff
Drop site.js
authorMichael Tremer <michael.tremer@ipfire.org>
Mon, 15 Oct 2018 13:54:55 +0000 (14:54 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Mon, 15 Oct 2018 13:54:55 +0000 (14:54 +0100)
We don't have any custom JS any more

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
src/static/js/site.js [deleted file]
src/templates/base.html

index 2937ac28e0b8ebb3ef63745321c7c21d2c0820b6..64034e9dc67ba894bf20aa35ec2b85c2c9b00dbd 100644 (file)
@@ -278,8 +278,7 @@ static_js_DATA = \
        src/bootstrap/dist/js/bootstrap.min.js.map \
        \
        src/static/js/jquery-3.3.1.min.js \
-       src/static/js/popper.min.js \
-       src/static/js/site.js
+       src/static/js/popper.min.js
 
 static_jsdir = $(staticdir)/js
 
diff --git a/src/static/js/site.js b/src/static/js/site.js
deleted file mode 100644 (file)
index ad94ee0..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-$.query = function(name){
-       var results = new RegExp('[\\?&]' + name + '=([^&#]*)').exec(window.location.href);
-       return results[1] || 0;
-}
-
-/* $(".planet-search-autocomplete").typeahead({
-       source: function(query, process) {
-               $.get("/api/planet/search/autocomplete", { q: query }, function(data) {
-                       if (data.query == query) {
-                               process(data.results);
-                       }
-               });
-       },
-}); */
-
-function getCookie(name) {
-       var r = document.cookie.match("\\b" + name + "=([^;]*)\\b");
-       return r ? r[1] : undefined;
-}
-
-jQuery.postJSON = function(url, args, callback) {
-       args._xsrf = getCookie("_xsrf");
-       $.ajax({url: url, data: $.param(args), dataType: "text", type: "POST",
-               success: function(response) {
-                       callback(eval("(" + response + ")"));
-               }
-       });
-};
index 129c4f4bb2467f481d8426f67039c5351f5c6d38..48fbbf05469048c5b84bb1d30ca6e77865495c9d 100644 (file)
                <script src="{{ static_url("js/jquery-3.3.1.min.js") }}"></script>
                <script src="{{ static_url("js/popper.min.js") }}"></script>
                <script src="{{ static_url("js/bootstrap.min.js") }}"></script>
-               <script src="{{ static_url("js/site.js") }}"></script>
                {% block javascript %}{% end block %}
        </body>
 </html>