From e78862437d6019de4a66a6682741632985413521 Mon Sep 17 00:00:00 2001 From: Anthony Talarico Date: Mon, 1 May 2017 16:09:45 -0400 Subject: [PATCH] removing unecessary code from the ajax-search queries and testing the ajax speed by removing the js code trying to figure out of the ajax calls are slow because of the network or the pending js operations that are done during the success functions --- js/app.js | 32 ++++++++++---------- js/custom/headerSearch.js | 32 ++++++++++---------- lib/ajax-search.php | 61 ++------------------------------------- 3 files changed, 35 insertions(+), 90 deletions(-) diff --git a/js/app.js b/js/app.js index 8915939..aa970a2 100644 --- a/js/app.js +++ b/js/app.js @@ -123,7 +123,7 @@ $(document).ready(function () { others: {'destination' : $('#destination-search option:selected').val(), 'park' : $('#park-search option:selected').val()} }, - complete: console.log("done"), + complete: console.log("done"), success:function(data){ var activity_data = data; @@ -220,31 +220,31 @@ $(document).ready(function () { }, complete: console.log("done"), success:function(data){ + console.log("SUCCESS"); var destination_data = data; option = {}; $('#activity-search option').not(':eq(0), :selected').remove(); var selected = $('#activity-search option:selected').val(); // counties.append($('