Skip to content
Fast Ajax- and API-router for PHP Micro-Framework HLEB
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Radjax (fast Ajax- and API-router)

The Radjax is not included in the original configuration of the framework HLEB, so it must be copied to the folder with the vendor/phphleb libraries from the repository or installed using Composer:

$ composer require phphleb/radjax

Connection to the project in /routes/ajax.php or /routes/api.php

Radjax\Route::get("/info/", ["get"], "App\Controllers\TestController@index", ["protected"=>false, "autoloader" => true]);

// and advanced customization

Radjax\Route::get("/weather/{y}/{m}/{d}/{h?}/", ["get","post"], "App\Controllers\TestController@weather", ["protected"=>true, "where"=>["y"=>"[0-9]+", "m"=>"[0-9]+", "d"=>"[0-9]+", "h"=>"[0-9]+"], "session_saved" => false]);
You can’t perform that action at this time.