Recently I was facing this problem. I used AJAX in .NET and posting was very smooth without any flicker. But the page transitions were painful. So I found this small piece of code over net.
This is two line implementation that will reduce page flicker during transition to minimum possible time. The only flicker that will remain intact will be if you are using heavy images on page. For textual stuff, you can never judge the difference.
Put following lines in the <HEAD> element of HTML page.
<meta http-equiv="Page-Enter" content="blendTrans(Duration=0)">
<meta http-equiv="Page-Exit" content="blendTrans(Duration=0)">
Now I am trying to display a loader during page load. I know that this is very easy as we are just calling a javascript function during Page-Enter and Page-Exit. I can call my own javascript function during these events who will start loader and then call blendTrans function.
I'll do it soon and will post that code over this blog as well.
By the way, this technique is called:
FAJAX
or
Fake-Ajax
Happy Coding

0 comments:
Post a Comment