• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 817
  • Last Modified:

Page Loading Indicator

I have an ASP page that takes approximately 45 seconds to load.  When loading the data, I would to display an animated GIF that indicates the page is being loaded.  I have tried several methods but I can't seem to display the image while the ASP loads.  Any information would be greatly appreciated.  Thank you.
0
TheChos
Asked:
TheChos
  • 2
1 Solution
 
bugs021997Commented:
Check this site....this should help you code...

http://authors.aspalliance.com/peterbrunone/pleasewait.asp
0
 
bugs021997Commented:
In the code below instead of the text Please Wait, you can add the image....

<BODY onLoad="cacheOff()">
    <!-- BEGINNING OF THE SCRIPT -->
    <STYLE TYPE="text/css">
    <!--
    #cache {
    position:absolute; left=10; top:10px; z-index:10; visibility:hidden;
    }
    -->
    </STYLE>
    <!--
    Lines above are creating a layer which show a message
    displaying the 'PLEASE WAIT ... ' message
    -->
    <SCRIPT LANGUAGE="JavaScript">
    ver = navigator.appVersion.substring(0,1)
    if (ver >= 4)
          {
          document.write('<DIV ID="cache"><TABLE WIDTH=400 BGCOLOR=#000000 BORDER=0 CELLPADDING=2 CELLSPACING=0><TR><TD ALIGN=center VALIGN=middle><TABLE WIDTH=100% BGCOLOR=#FFFFFF BORDER=0 CELLPADDING=0 CELLSPACING=0><TR><TD ALIGN=center VALIGN=middle><FONT FACE="Arial, Verdana" SIZE=4><B><BR>PLEASE WAIT ... <BR><BR></B></FONT></TD> </TR></TABLE></TD> </TR></TABLE></DIV>');
          var navi = (navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 4);
          var HIDDEN = (navi) ? 'hide' : 'hidden';
          var VISIBLE = (navi) ? 'show' : 'visible';
          var cache = (navi) ? document.cache : document.all.cache.style;
          largeur = screen.width;
          cache.left = Math.round(100);
          cache.visibility = VISIBLE;
          }
    function cacheOff()
          {
          if (ver >= 4)
                {
                cache.visibility = HIDDEN;
                }
          }
    </SCRIPT>
0
 
TheChosAuthor Commented:
Very nice!  Thank you.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now