I need paypal integration for paying order. What I already do is to integrate api http://ci-merchant.org/. It works like it needs to.. go to paypal website, give me option to pay but after i press pay button it just relocate to my sucess definded page and offcourse doesnt make payment. Here is my php code for paypal:
$this->load->library('merchant');
$this->merchant->load('paypal_express');
$settings = $this->merchant->default_settings();
$settings = array(
'username' => '*',
'password' => '*',
'signature' => '*',
'test_mode' => false,
'solution_type' => array('type' => 'select', 'default' => 'Sole', 'options' => array(
'Sole' => 'merchant_solution_type_sole',
'Mark' => 'merchant_solution_type_mark')),
'landing_page' => array('type' => 'select', 'default' => 'Billing', 'options' => array(
'Billing' => 'merchant_landing_page_billing',
'Login' => 'merchant_landing_page_login')));
$this->merchant->initialize($settings);
if(isset($_POST['pay'])){
$params = array(
'amount' => '0.20',
'currency' => 'USD',
'return_url' => 'pay/succesfull',
'cancel_url' => 'pay/cancel');
$response = $this->merchant->purchase($params);
if ($response->success()){
echo "paid sucesfuly";
}
else
{
$message = $response->message();
echo('Error processing payment: ' . $message);
exit;
}
Here is print screen where should paying be completed, but after pressing Pay now it just goes to my sucessfull website.
It sounds like you're not completing the process. The entire flow of Express Checkout is...
Sounds like you've got #1 - 4 taken care of, and maybe even #5, but you're missing #6. Until DECP is called, no transaction actually takes place. You must be missing that piece.
Find solution with other PayPal library and works pefect, here is link if someone else would need it https://github.com/jersonandyworks/Paypal-Library-by-RomyBlack.