PHP code example of uniondrug / service-server
1. Go to this page and download the library: Download uniondrug/service-server 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/ */
uniondrug / service-server example snippets
public function postAction(){
$total = 123;
$page = 3;
$limit = 15;
$data = [
["id" => 1, "key" => "value"],
["id" => 2, "key" => "value2"]
];
$this->serviceServer->setPaging($total, $page, $limit)->withPaging($data);
}