You can redirect an ASP.NET page using one of three methods. The first method is through metatag redirection. If that fails, then it will try to redirect with JavaScript. If that fails, a URL will be displayed that the user can click on to redirect the page.
An HTML 5 only version of this redirect page can be found in the post Redirecting Pages in HTML 5.
— ASP.NET code below —
<%@ Page Language=”C#” %>
<!DOCTYPE html>
<script runat=”server”>
<head runat=”server”>
<title>Page Title</title>
<meta http-equiv=”Refresh” content=”0; url=”>
<!– If the meta tag doesn’t work, try JavaScript to redirect. –>
<script type=”text/javascript”>
window.location.href = “”
<form id=”form1″ runat=”server”>
<!– If JavaScript doesn’t work, give a link to click on to redirect. –>
<p>If you are not redirected automatically, click <a href=’’>here</a>.</p>

Print Friendly, PDF & Email
Translate ยป