PHP code example of vinceurag / simplyrest

1. Go to this page and download the library: Download vinceurag/simplyrest 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/ */

    

vinceurag / simplyrest example snippets


composer global 
config/database.php

DO NOT MODIFY ANYTHING IN THE /core FOLDER AND index.php
$this->sendResponse()
core/HTTP_Status.php

$anyVariable $this->getJsonData()
$this->
$this->load_model("anothermodel")
$this->anothermodel->getUser()

$this->db->exec("SELECT * FROM tbl_users");

$this->db->udapte_record($table, $arrayChanges, "id=condition");
config/routes.php
:param
:param

$route['about/name/:param/age/:param'] = "test/nameage";

$this->jwt->check()