[gimp-web/testing] Change tipuesearch to static mode (js vs json)



commit 094f6907933ae56857e9ba70c1421b804a066270
Author: Pat David <patdavid gmail com>
Date:   Fri Mar 3 09:56:00 2017 -0600

    Change tipuesearch to static mode (js vs json)
    
    CSP (or strict MIME typing in chrome?) was blocking the old .json
    file from loading/executing.  I changed to static mode for search
    which uses a .js file instead - which does work.
    
    Apparently I did this work a few months back already, just hadn't
    made the one change to enable it.

 plugins/tipue_search/tipue_search.py |    2 +-
 themes/newgimp/templates/search.html |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/plugins/tipue_search/tipue_search.py b/plugins/tipue_search/tipue_search.py
index 54471c3..3649ed6 100644
--- a/plugins/tipue_search/tipue_search.py
+++ b/plugins/tipue_search/tipue_search.py
@@ -88,7 +88,7 @@ class Tipue_Search_JSON_Generator(object):
 
 
     def generate_output(self, writer):
-        path = os.path.join(self.output_path, 'tipuesearch_content.json')
+        path = os.path.join(self.output_path, 'tipuesearch_content.js')
 
         pages = self.context['pages'] + self.context['articles']
 
diff --git a/themes/newgimp/templates/search.html b/themes/newgimp/templates/search.html
index 5784870..57365e0 100644
--- a/themes/newgimp/templates/search.html
+++ b/themes/newgimp/templates/search.html
@@ -38,7 +38,7 @@
         <script src="/js/jquery.min.js"></script>
 
         <link href="theme/css/tipuesearch/tipuesearch.css" rel="stylesheet">
-        <script src="/tipuesearch_content.json"></script>
+        <script src="/tipuesearch_content.js"></script>
         <script src="/js/tipuesearch_set.js"></script>
         <script src="/js/tipuesearch.min.js"></script>
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]