Link to home
Start Free TrialLog in
Avatar of spop12
spop12

asked on

displaying waiting page

I have a webpage that get the data from database and it takes quite awhile to do this and i want to display it as soon as it done...
the problem is before i display the data I want the user to see the another page with a .gif animation on it and it said "please wait, processing your order."
how do I do this ? i did java script "onLoad" and redirected to the result on the waiting page but the gif image doesn't animate.

here is the waiting page

     <html>
     <script type="text/javascript">
         
          function loadit(){
               window.location = 'result.asp?sOrder=10';
          }
     </script>
     <title>processing order</title>
     <body onLoad="loadit()">
          <h1 class="PageHeads">processing <img src="../progress_ani.gif" border="0"></h1>
     </body>
     </html>    

ASKER CERTIFIED SOLUTION
Avatar of chriscaputo
chriscaputo

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of hansamryan
hansamryan

I would have to agree with Chris on this one.
Use this

'Main File
<Form Action="Progress.Asp" Method="POST">
Name : <Input Type=Text Name="txtName"><Br><Br>
<Input Type=Submit>
</Form>

'Progress.Asp
<%
  Session("txtName")=Request.Form("txtName")
%>
<Body OnLoad="Javascript:document.location='Query.Asp';">
<Img Src="yourgif.gif">

'Query.Asp
<%
  Dim con,rst
  Set con=Server.createObject("ADODB.Connection")
  Set rst=Server.CreateObject("ADODB.REcordSet")

  con.OPen  'Place open code here
  rst.Open "Select * from Table Where Name='" & Session("txtName") & "'"

  'Do the rest here
%>