PHP code example of miszhou / wxpay

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

    

miszhou / wxpay example snippets


curl_setopt($ch,CURLOPT_SSL_VERIFYPEER, TRUE);
curl_setopt($ch,CURLOPT_SSL_VERIFYHOST, 2);//严格校验

curl_setopt($ch,CURLOPT_SSL_VERIFYPEER, FALSE);  
curl_setopt($ch,CURLOPT_SSL_VERIFYHOST, 0);//取消校验