Wednesday, November 11, 2009

Auto Redirect a page

Their are two way to auto redirect a page


using meta tag
using response.addheader


using Meta Tag
<meta http-equiv="refresh" content="5; url=http://bharatkushwaha.blogspot.com" />


using response.addHeader



   string url = "Default.aspx";
        Response.AddHeader("REFRESH", "2;URL='" + url + "'");
        Label1.Text = "<b>You will be redirected to Category automaticallly within few seconds";
        Label1.ForeColor = System.Drawing.Color.Green;

No comments:

Post a Comment