[ckan-dev] JavaScript issues using https

Aníbal Pacheco anibal.pacheco at agesic.gub.uy
Thu Mar 27 19:31:23 UTC 2014


Hello, I'm facing a problem when loading /api/i18n/... when the site is 
used under https, the browser prevents to load thigs from http, here is 
the error in firebug (sorry for the spanish version):

> Se bloqueó la carga del contenido activo mixto "http://catalogodatos.gub.uy/api/i18n/es"
> https://catalogodatos.gub.uy/fanstatic/vendor/:version:2014-03-18T16:20:19.93/jquery.min.js
> Line 524

This error is causing that for example the layout in the organizations 
view can't finish to render and the blocks get unaligned.
Ok, I can fix this issue with this patch:

--- a/ckan/public/base/javascript/client.js
+++ b/ckan/public/base/javascript/client.js
@@ -102,7 +102,7 @@
       * Returns a jQuery xhr promise.
       */
      getLocaleData: function (locale, success, error) {
-      var url = this.url('/api/i18n/' + (locale || ''));
+      var url = this.url('https://catalogodatos.gub.uy/api/i18n/' + 
(locale || ''));
        return jQuery.getJSON(url).then(success, error);
      },


But when i fix it, I get my select boxes broken again like I post a few 
days ago in a post subject "Problem with select boxes"

Any thoughts? Thank you!

-- 
Ing. Aníbal Pacheco

Área de Tecnología
AGESIC
Torre Ejecutiva Sur
Liniers 1324 piso 3
Tel: (+598) 2901 2929 Int. 8524
(11.000) Montevideo – URUGUAY
www.agesic.gub.uy



More information about the ckan-dev mailing list