PHP code example of twenlike / php-huaweisdk
1. Go to this page and download the library: Download twenlike/php-huaweisdk 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/ */
twenlike / php-huaweisdk example snippets
namespace App\Controllers\Api\BigScreen;
use App\Controllers\BaseController;
use App\Libraries\huaweisdk\Huawei;
class Test extends BaseController
{
// 华为连接DataArts测试
public function index(){
// $data = [
// "url" => "/test", // 请求地址
// "query" => [ // 请求query参数
// "data_time" => "2023-01-01",
// "type" => 1,
// ],
// "body" => [ // 请求body 参数
// "data_time" => "2023",
// "type" =>1
// ]
// ];
$data = Huawei::getData($data);
var_dump($data);die();
}
}