Depending on the rest of your site, the difference in latency between the CDN 
request and a request to your server is probably so minimal compared to the 
overall load time it really isn’t worth it, especially when you consider that 
it’s being cached by the browser.

In any case, fusebox.head.addCSS is meant for accessing *local* files. I guess 
that method must have changed between v4.5 and v5, because as it is now it 
would never work.

If you are always loading that css, there is no point in using 
fusebox.head.addCSS, just put it directly in the <head> of the layout. If you 
are only loading that css in certain circuits, then you should still probably 
put it in the layout, but put surround it with a test for the circuit (check 
$fusebox{“circuit”}).

Otherwise, if you’re determined to use fusebox.head.addCSS for an external 
stylesheet, you have to do it like this:

fusebox.head.addCSS($fusebox; "!<link rel=\"stylesheet\" type=\"text/css\" 
href=\"https://cdnjs.cloudflare.com/ajax/libs/bootstrap3-dialog/1.35.4/css/bootstrap-dialog.min.css\
 
<https://cdnjs.cloudflare.com/ajax/libs/bootstrap3-dialog/1.35.4/css/bootstrap-dialog.min.css%5C>"
 />")


> On Jun 14, 2017, at 8:33 AM, Doug Hall <doughall...@gmail.com> wrote:
> 
> I'm converting from an old Active4D 4.5 site to the latest version (6.4r3
> as I understand it). I noticed that this no longer downloads :
> 
>  fusebox.head.addCSS($fusebox;"//
> cdnjs.cloudflare.com/ajax/libs/bootstrap3-dialog/1.35.4/css/bootstrap-dialog.min.css
> ")
> 
> If you'll check the actual URL, you'll see that it's fine. The generated
> html from the page source looks the same, too. Is there something else I'm
> not thinking about that could stop the download? This is the only place on
> my site where I'm downloading CSS from a CDN. I know I could serve it
> locally, and it is really small, but I thought it might be abit faster from
> a CDN. Any "best practice" advice on this would be welcomed, too.
> 
> Thanks,
> Doug Hall
> _______________________________________________
> Active4D-dev mailing list
> Active4D-dev@aparajitaworld.com
> http://list.aparajitaworld.com/listinfo/active4d-dev
> Archives: http://active4d-nabble.aparajitaworld.com/

_______________________________________________
Active4D-dev mailing list
Active4D-dev@aparajitaworld.com
http://list.aparajitaworld.com/listinfo/active4d-dev
Archives: http://active4d-nabble.aparajitaworld.com/

Reply via email to