PHP code example of 96qbhy / lbscloud-sdk

1. Go to this page and download the library: Download 96qbhy/lbscloud-sdk 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/ */

    

96qbhy / lbscloud-sdk example snippets




$config = [
    'ak' => '百度lbs ak',
];

$lbs = new \Qbhy\LBSCloud\LBSCloud($config);

// 云存储服务
$storage = $lbs->storage;
// 云检索服务
$search = $lbs->search;
// 云地理编码服务
$gc = $lbs->gc;
// 云逆地利编码服务
$rcg = $lbs->rgc;

/**
 * $service->request('fn',[])
 * 云存储服务已经封装了部分业务方法,如 tableCreate、tableQuery、poiCreate、poiQuery 等,如你需要的方法不在已封装的方法内,你可以自行封装,然后提 PR 给我。
 * 其他服务的业务方法暂未封装,原则上我用到的时候会进行封装,当然也欢迎 PR。
 */