Go Back   Dreamweaver Club Forums > Hand Coders Forum > Javascript and JS frameworks
Register FAQ Members List Search Today's Posts Mark Forums Read

Thread Tools Display Modes
Old 02-28-2011, 10:54 PM   #1
Join Date: Feb 2009
Posts: 129
Cool jQuery - set var whilst loading, call on load IE problem


When my page is loading it uses the Facebook Javascript API to determine whether or not a user is signed in to Facebook, if they are signed in
window._signedInToFacebook = true;
... otherwise ...
window._signedInToFacebook = false;
Then one the page has loaded I want to - for testing purposes - show the value of the _signedInToFacebook in an alert message, however, when I run the jQuery code
if ($.browser.msie) {
} else {
in Chrome everything works perfectly, but - no surprise - IE just throws an 'undefined' message at me.

Even if I try:
<body onLoad="alert(window._signedInToFacebook);">
I still get no luck, I've done some routing around but can't find anything like this I guess because its quite specific criteria...

Does anyone know how to correct this?

By the way I'm using newest Chrome release and IE9 beta...

Thanks in advance
Adam_C is offline   Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT. The time now is 11:10 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com