Skip to content

Paypal sand box #2

@mogahead

Description

@mogahead

is this need to require the gateway package in composer beside your package or not
when i set testmode to false this is error response haven't redirect ....
when i set it to true the record back with success but the transaction didn't save in sand box transaction or the funds effect this is any reason hear is my code

use Omnipay;

public function getApiInfos() {
  return array(
    'cancelUrl' => URL::route('paypal_response'),
    'returnUrl' => URL::route('success_paypal_response'),
    'amount'    => '50.00',
    'currency'  => 'USD',
    'description' => '#description'
  );
}



public function upgrade_acount_processing()
{

// make paypal payment

$gateway = Omnipay::gateway('PayPal_Express');
    $gateway->setUsername('xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx');
    $gateway->setPassword('xxxxxxxxxxxxxxxxx');
    $gateway->setSignature('xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx');
    $gateway->setTestMode(true);

    $response = $gateway->purchase($this->getApiInfos())->send();
    return $response->redirect();
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions