Reputation: 1
I am using Ci merchant in my codeigniter , but i got this error , can u please mention what should i do ?
public function mypaypal() { echo "mypaypal"; }
public function cancel() { echo "cancelled"; }
public function index() {
$this->load->library('merchant'); $this->merchant->load('paypal_express'); $settings = array( 'username' => '******', 'password' => '******', 'signature' => '********', 'test_mode' => true ); $this->merchant->initialize($settings); $params = array( 'amount' => 1.00, 'currency' => 'USD', 'return_url' => base_url().'mypaypal', 'cancel_url' => base_url().'cancel'); $response = $this->merchant->purchase($params); var_dump($response); if ($response->success()) { var_dump($response); } else { $message = $response->message(); echo('Error processing payment: '); exit; } }
and i got this error :
object(Merchant_response)#17 (8) { ["_status":protected]=> string(6) "failed" ["_message":protected]=> string(51) "Problem with the SSL CA cert (path? access rights?)" ["_reference":protected]=> NULL ["_data":protected]=> NULL ["_redirect_url":protected]=> NULL ["_redirect_method":protected]=> string(3) "GET" ["_redirect_message":protected]=> NULL ["_redirect_data":protected]=> NULL }
Upvotes: 0
Views: 684
Reputation: 13263
Problem with the SSL CA cert (path? access rights?)
Your server doesn't have a root SSL certificate set up correctly (it uses this to verify that outgoing connections are connecting to the right server).
I recommend using Omnipay (the successor to CI-Merchant), as this uses Guzzle for HTTP connections, which comes bundled with the latest root SSL certificate so you don't need to worry about your server having them installed.
Upvotes: 0