Prado\Web\THttpRequest::getRequestType PHP Méthode

getRequestType() public méthode

public getRequestType ( ) : string
Résultat string request type, can be GET, POST, HEAD, or PUT
    public function getRequestType()
    {
        return isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : null;
    }

Usage Example

Exemple #1
0
 public function testGetRequestType()
 {
     $request = new THttpRequest();
     self::assertEquals('GET', $request->getRequestType());
 }