Google API's & Intranet/Local Test

6 posts by 2 authors in: Forums > CMS Builder
Last Post: October 13, 2017   (RSS)

By jenolan - July 3, 2017

I do a lot of work on non-internet based systems, the 'cmsb/lib/menus/header.php' tries to load from 'googleapis.com' problem of course is that there is no access and it has to time out multiple times for each of the fonts & javascript.

Could we please have a setting in the control panel  that will tell the system NOT to try and do stuff over the internet.

Thanks
Larry

---



Peace and Long Life

By Dave - July 4, 2017

Hi Larry, 

There's a fallback in the code: 

  <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
  <script>window.jQuery || document.write('<script src="<?php echo CMS_ASSETS_URL ?>/3rdParty/jquery-1.11.2.min.js"><\/script>')</script>

Does that not work?  Or is the issue just that it's slow?  

Dave Edis - Senior Developer
interactivetools.com

By jenolan - July 4, 2017

S-L-O-W ... hugely ;-)

Also, the fonts don't have a fallback, went and looked. When it gets me grumpy I mod the file to remove the external calls but obviously that only works to the next update and then it goes slow again.

Cheers
Larry

---



Peace and Long Life

By Dave - July 5, 2017

Hmm, ok. Do the computers have no network access, or no internet access?  I'm wondering about the javascript method navigator.isOnline?
https://developer.mozilla.org/en-US/docs/Web/API/NavigatorOnLine/onLine

As we go along there are more and more internet related services which add value to the software (spellcheck, etc).  Perhaps an option like one of the following under: Admin > General > Advanced Settings

- Offline Mode [_] Use local resources whenever possible instead of Content Deliver Networks or remote resources (for offline installations)

Or

- Use CDNs [X] Use Content Delivery Networks and other internet hosted resources when possible to speed up page loading time (eg: jquery, etc)

I'll work on the wording and add that to the next release.  Let me know any feedback and places in the code you update if other than jquery.

Dave Edis - Senior Developer
interactivetools.com

By Dave - October 13, 2017

Hi All, 

Just wanted to update you that we've fixed this for the next release.  We've opted to go with all local files for now rather than maintaining the option for local and remote files.  If speed becomes an issue (I don't think it will) we can always add more caching on the backend in future.  

Thanks!

Dave Edis - Senior Developer
interactivetools.com