Redirection of page from http to https using VB.net
If Not Request.IsSecureConnection Then
Dim redirectUrl As String = Request.Url.ToString().Replace("http:", "https:")
Response.Redirect(redirectUrl)
End If
Redirection of page from http to https using C#
if(!Request.IsSecureConnection)
{
string redirectUrl = Request.Url.ToString().Replace("http:", "https:");
Response.Redirect(redirectUrl);
}
If Not Request.IsSecureConnection Then
Dim redirectUrl As String = Request.Url.ToString().Replace("http:", "https:")
Response.Redirect(redirectUrl)
End If
Redirection of page from http to https using C#
if(!Request.IsSecureConnection)
{
string redirectUrl = Request.Url.ToString().Replace("http:", "https:");
Response.Redirect(redirectUrl);
}
No comments:
Post a Comment