How to test for connection to website?

Soldato
Joined
18 Oct 2003
Posts
19,415
Location
Midlands
Aloha all,

I'm stuck. I have a web app. On the front page we have a Facebook social plugin that is sometimes blocked by company policy. When it's blocked it looks.. bad.

What I'd like to do is test to see if Facebook is accessible at that point in time and if not provide my own image rather than the plugin.

Does anyone know of a way to evaluate whether Facebook is accessible on load through JS?

Any help is much appreciated.

Thanks
 
Well the FB social plugin I'm using is the iframe implementation. So I definitely could look for a unique element, but going about that I'm unsure. Would it happen fast enough to be a seamless load?
 
Back
Top Bottom