1. Go to this page and download the library: Download code-lives/baidu 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/ */
code-lives / baidu example snippets
composer
//引入命名空间
use Applet\Assemble\Baidu;
$pay= Baidu::init($config)->set("订单号","金额","描述","描述")->getParam();