Prado\Web\THttpRequest::getIsSecureConnection PHP Method

getIsSecureConnection() public method

public getIsSecureConnection ( ) : boolean
return boolean if the request is sent via secure channel (https)
    public function getIsSecureConnection()
    {
        return isset($_SERVER['HTTPS']) && strcasecmp($_SERVER['HTTPS'], 'off');
    }

Usage Example

Beispiel #1
0
 public function testGetIsSecureConnection()
 {
     $request = new THttpRequest();
     self::assertEquals(false, $request->getIsSecureConnection());
 }