How to fix curl_exec returns false
<p>I am developing payment with PHP for weixin.
The code that I implemented as follow.
But curl_exec return false and </p>

<pre><code>    $ch = curl_init();
    curl_setopt($ch, CURLOPT_TIMEOUT, $second);
    if(WxPayConfig::CURL_PROXY_HOST != "0.0.0.0"
        &amp;&amp; WxPayConfig::CURL_PROXY_PORT != 0){
        curl_setopt($ch,CURLOPT_PROXY, WxPayConfig::CURL_PROXY_HOST);
        curl_setopt($ch,CURLOPT_PROXYPORT, WxPayConfig::CURL_PROXY_PORT);
    }
    curl_setopt($ch,CURLOPT_URL, $url);
    curl_setopt($ch,CURLOPT_SSL_VERIFYPEER,TRUE);
    curl_setopt($ch,CURLOPT_SSL_VERIFYHOST,2);

    curl_setopt($ch, CURLOPT_HEADER, FALSE);

    curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);

    if($useCert == true){
        curl_setopt($ch,CURLOPT_SSLCERTTYPE,'PEM');
        curl_setopt($ch,CURLOPT_SSLCERT, WxPayConfig::SSLCERT_PATH);
        curl_setopt($ch,CURLOPT_SSLKEYTYPE,'PEM');
        curl_setopt($ch,CURLOPT_SSLKEY, WxPayConfig::SSLKEY_PATH);
    }

    curl_setopt($ch, CURLOPT_POST, TRUE);
    curl_setopt($ch, CURLOPT_POSTFIELDS, $xml);

    $data = curl_exec($ch);
</code></pre>

<p>I catch the error message of curl_exec and the message as following.</p>

<p>"SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed"</p>