asp.net 頁面延時(shí)五秒,跳轉(zhuǎn)到另外的頁面
更新時(shí)間:2009年12月07日 19:57:32 作者:
asp.net 頁面延時(shí)五秒,跳轉(zhuǎn)到另外的頁面的實(shí)現(xiàn)代碼。
--前臺(tái)
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Successed.aspx.cs" Inherits="Biz_Order_Successed" %>
<!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>
</head>
<body>
<form id="form1" runat="server">
<div style="height: 100px">
</div>
<div align="center">
<asp:Label ID="lbmessage" runat="server" Font-Size="Large" Font-Bold="true"></asp:Label>
<br />
<br />
<font size="4" >
系統(tǒng)將會(huì)在五秒鐘后轉(zhuǎn)向?yàn)g覽頁面
</font>
<br />
<br />
<font color="blue" size="4" ><a id="hrefUrl" href="" style="text-decoration: underline" runat="server"></a></font>
</div>
</form>
</body>
</html>
--后臺(tái)
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using HyiSoft.WebUtility;
public partial class Biz_Order_Successed : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
string message = string.Empty;
string url = string.Empty;
url = Utility.Request("url");
message = Utility.Request("message");
lbmessage.Text = message;
hrefUrl.HRef = url;
hrefUrl.InnerText = "手動(dòng)轉(zhuǎn)向頁面";
string strRedirectPage = url;
string strRedirectTime = "5";
string strRedirect = string.Format("{0};url={1}", strRedirectTime, strRedirectPage);
Response.AddHeader("refresh", strRedirect);
}
}
復(fù)制代碼 代碼如下:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Successed.aspx.cs" Inherits="Biz_Order_Successed" %>
<!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>
</head>
<body>
<form id="form1" runat="server">
<div style="height: 100px">
</div>
<div align="center">
<asp:Label ID="lbmessage" runat="server" Font-Size="Large" Font-Bold="true"></asp:Label>
<br />
<br />
<font size="4" >
系統(tǒng)將會(huì)在五秒鐘后轉(zhuǎn)向?yàn)g覽頁面
</font>
<br />
<br />
<font color="blue" size="4" ><a id="hrefUrl" href="" style="text-decoration: underline" runat="server"></a></font>
</div>
</form>
</body>
</html>
--后臺(tái)
復(fù)制代碼 代碼如下:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using HyiSoft.WebUtility;
public partial class Biz_Order_Successed : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
string message = string.Empty;
string url = string.Empty;
url = Utility.Request("url");
message = Utility.Request("message");
lbmessage.Text = message;
hrefUrl.HRef = url;
hrefUrl.InnerText = "手動(dòng)轉(zhuǎn)向頁面";
string strRedirectPage = url;
string strRedirectTime = "5";
string strRedirect = string.Format("{0};url={1}", strRedirectTime, strRedirectPage);
Response.AddHeader("refresh", strRedirect);
}
}
相關(guān)文章
Entity?Framework?Core關(guān)聯(lián)刪除
關(guān)聯(lián)刪除通常是一個(gè)數(shù)據(jù)庫術(shù)語,用于描述在刪除行時(shí)允許自動(dòng)觸發(fā)刪除關(guān)聯(lián)行的特征;即當(dāng)主表的數(shù)據(jù)行被刪除時(shí),自動(dòng)將關(guān)聯(lián)表中依賴的數(shù)據(jù)行進(jìn)行刪除,或者將外鍵更新為NULL或默認(rèn)值。本文將為大家具體介紹一下Entity?Framework?Core關(guān)聯(lián)刪除,需要的可以參考一下2021-12-12
ASP.NET Core MVC 中實(shí)現(xiàn)中英文切換的示例代碼
這篇文章主要介紹了ASP.NET Core MVC 中實(shí)現(xiàn)中英文切換的示例代碼,文中通過示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)學(xué)習(xí)吧2020-02-02
基于.net core微服務(wù)的另一種實(shí)現(xiàn)方法
這篇文章主要給大家介紹了基于.net core微服務(wù)的另一種實(shí)現(xiàn)方法,文中通過示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)學(xué)習(xí)吧2018-07-07
Silverlight4 多語言實(shí)現(xiàn)的方法
這篇文章介紹了Silverlight4 多語言實(shí)現(xiàn)的方法,有需要的朋友可以參考一下2013-10-10
FileUpload1 上傳文件類型驗(yàn)證正則表達(dá)式
FileUpload1 上傳文件類型驗(yàn)證正則表達(dá)式...2006-10-10
解決Win10無法安裝.Net Framework 3.5提示錯(cuò)誤代碼0x800F081F
這篇文章主要介紹了Win10無法安裝.Net Framework 3.5提示錯(cuò)誤代碼0x800F081F的完美解決方法,需要的朋友可以參考下2017-12-12
創(chuàng)建基于ASP.NET的SMTP郵件服務(wù)的具體方法
Asp.net在System.Web.Mail名稱空間中有一個(gè)發(fā)送email的內(nèi)建類,但這僅是cdosys的一個(gè)假象。開發(fā)者能使用一個(gè)替代的它smtp郵件服務(wù)。在這篇文章里面,我將會(huì)展示如何創(chuàng)建一個(gè)用于asp.net的功能齊全的smtp郵件服務(wù)2013-11-11

