I have a legacy classic ASP page that is taking a long time to load. This is because before loading it must run a large number of database queries. Load time is upwards of 10 seconds.
The page structure looks like this:
<% SQL Queries %>
<html>...Display the data from the queries..</html>
Classic ASP comes with the handy Response.Flush command. Such code will cause content to appear before the SQL queries start executing:
<% Response.Write("<div id=""PleaseWaitPanel"">") Response.Write("Processing, please wait...") Response.Write("<img src=""please_wait.gif"" />") Response.Write("</div>") Response.Flush() 'SQL Queries... %>
Now to hide it after queries are done you need simple jQuery: