System.Web Namespace HttpRequest Class
Gets a value indicting whether the HTTP connection uses secure sockets ( that is, HTTPS ).
[ VB ]
Public ReadOnly Property IsSecureConnection As Boolean
[ C# ]
public bool IsSecureConnection {get;}
[ C++ ]
public: __property bool get_IsSecureConnection ( );
[ JScript ]
public function get IsSecureConnection ( ) : Boolean;
true if the connection is secure; otherwise, false.
The following example shows the simplest way to retrieve and display the IsSecureConnection for the current URL request.
<%= Request.IsSecureConnection %>
Show me
HttpRequest Members