ASP. NET Enables automatic page Jump(Tested, it can be passed in vs2008 C # environment)
<% @ Page Language = "C #" autoeventwireup = "true" codefile = "default. aspx. cs" inherits = "_ default" %>
<! Doctype HTML public "-// W3C // dtd xhtml 1.0 transitional // en" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<HTML xmlns = "http://www.w3.org/1999/xhtml">
<Head runat = "server">
<Title> </title>
<SCRIPT type = "text/JavaScript">
VaR I = 5;
// Obtain logon events and handle Automatic redirects
Window. onload = function jumppage ()
{
Document. getelementbyid ("time"). innertext = I;
// Jump immediately after the timer is 0
I --;
If (I <0)
{
Location. Replace ("http://www.baidu.com ");
}
SetTimeout ("jumppage ()", 1000 );
}
</SCRIPT>
</Head>
<Body>
<Form ID = "form2" runat = "server">
<Div id = "autojumppage">
Welcome to the <span id = "time" style = "color: # ff0000 "> </span> seconds after automatic jump to <a href =" http://www.baidu.com "> Baidu </a>
<Br/>
If you want to jump to the page immediately, click <a href = "http://www.baidu.com" style = "color: # ff00ff"> jump now >></A>
</Div>
</Form>
</Body>
</Html>