Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

That's been one of my concerns, the best way to circumvent that issue is to do something like the following:

   <script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
   <script>window.jQuery || document.write(unescape("%3Cscript src='/path/to/jquery.js' type='text/javascript'%3E%3C/script%3E"));</script>
This way it will fallback to a local copy if Google's goes down.

[Edit: simonsarris replied with something similar as I was replying, however, the advantage of using unescape is that you don't get invalid markup warnings]



Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: