I am redirecting my user to my default.aspx when his session expires and default page is referenced under a master page. I show a notification like twitter stating Session
I could not find the place where topBar
is called, but if I call it from $(document).ready()
it worked like a charm in my IE8:
You could also use $(window).load()
if you have graphics and/or other heavy elements that needs to be loaded before topBar()
is called:
$(window).load(function() {
topBar("Hello world!");
});
Hope it helps.
EDIT:
Maybe this can be of some help? Basically you could do something like this:
ScriptManager.RegisterClientScriptBlock(this, typeof(Page), "json",
@"$(document).ready(function(){
topBar("Hello world!");
});
});", true);
Check out the answer in the link because he gives a couple of alternatives