PHP code example of ilias / opherator

1. Go to this page and download the library: Download ilias/opherator library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ilias / opherator example snippets




use Ilias\Opherator\\Request;

Request::setup();

class Request
{
  public static function getMethod() : string;

  public static function getBody(): array;

  public static function getQuery(): array;

  public static function hasBody(): bool;
}

class Response
{
  public static function setResponse(array $response): void;

  public static function appendResponse(string $key = "data", string|array $response, bool $override = true): void;

  public static function jsonResponse(): void;

  public static function htmlResponse(): void;

  public static function answer(): void;
}