function __construct($method,$paypalPlugin) { parent::__construct($method,$paypalPlugin); //Set the credentials if ($this->_method->sandbox ) { $this->api_login_id = $this->_method->sandbox_api_login_id; $this->api_signature = $this->_method->sandbox_api_signature; $this->api_password = $this->_method->sandbox_api_password; $this->payflow_partner = $this->_method->sandbox_payflow_partner; $this->payflow_vendor = $this->_method->sandbox_payflow_vendor; } else { $this->api_login_id = $this->_method->api_login_id; $this->api_signature = $this->_method->api_signature; $this->api_password = $this->_method->api_password; } if (empty($this->api_login_id) || empty($this->api_signature) || empty($this->api_password)) { $text = JText::sprintf('VMPAYMENT_PAYPAL_CREDENTIALS_NOT_SET', $this->_method->payment_name, $this->_method->virtuemart_paymentmethod_id); vmError($text, $text); } if ((empty ($this->_method->payflow_partner) OR empty($this->_method->sandbox_payflow_partner))) { $sandbox = ""; if ($this->_method->sandbox ) { $sandbox = 'SANDBOX_'; } $text = JText::sprintf('VMPAYMENT_PAYPAL_PARAMETER_REQUIRED', JText::_('VMPAYMENT_PAYPAL_' . $sandbox . 'PAYFLOW_PARTNER'), $this->_method->payment_name, $this->_method->virtuemart_paymentmethod_id); vmError($text); } }
function __construct($method, $paypalPlugin) { parent::__construct($method, $paypalPlugin); //Set the credentials if ($this->_method->sandbox) { $this->api_login_id = $this->_method->sandbox_api_login_id; if ($this->_method->authentication == 'signature') { $this->api_signature = trim($this->_method->sandbox_api_signature); $this->api_certificate = ''; } else { $this->api_signature = ''; $this->api_certificate = trim($this->_method->sandbox_api_certificate); } $this->api_password = trim($this->_method->sandbox_api_password); $this->merchant_email = trim($this->_method->sandbox_merchant_email); } else { $this->api_login_id = trim($this->_method->api_login_id); $this->api_signature = trim($this->_method->api_signature); $this->api_certificate = trim($this->_method->api_certificate); $this->api_password = trim($this->_method->api_password); $this->merchant_email = trim($this->_method->paypal_merchant_email); } if (!$this->ExpCredentialsValid() or !$this->isAacceleratedOnboardingValid()) { $text = vmText::sprintf('VMPAYMENT_PAYPAL_CREDENTIALS_NOT_SET', $this->_method->payment_name, $this->_method->virtuemart_paymentmethod_id); vmError($text, $text); } if (empty($this->_method->expected_maxamount)) { $text = vmText::sprintf('VMPAYMENT_PAYPAL_PARAMETER_REQUIRED', vmText::_('VMPAYMENT_PAYPAL_EXPECTEDMAXAMOUNT'), $this->_method->payment_name, $this->_method->virtuemart_paymentmethod_id); vmError($text, $text); } }
function __construct($method, $paypalPlugin) { parent::__construct($method, $paypalPlugin); //Set the credentials if ($this->_method->sandbox) { $this->merchant_email = $this->_method->sandbox_merchant_email; } else { $this->merchant_email = $this->_method->paypal_merchant_email; } if (empty($this->merchant_email)) { $sandbox = ""; if ($this->_method->sandbox) { $sandbox = 'SANDBOX_'; } $text = vmText::sprintf('VMPAYMENT_PAYPAL_PARAMETER_REQUIRED', vmText::_('VMPAYMENT_PAYPAL_' . $sandbox . 'MERCHANT'), $this->_method->payment_name, $this->_method->virtuemart_paymentmethod_id); vmError($text, $text); return FALSE; } }
function __construct($method, $paypalPlugin) { parent::__construct($method, $paypalPlugin); //Set the credentials if ($this->_method->sandbox) { $this->api_login_id = trim($this->_method->sandbox_api_login_id); $this->api_signature = trim($this->_method->sandbox_api_signature); $this->api_password = trim($this->_method->sandbox_api_password); } else { $this->api_login_id = trim($this->_method->api_login_id); $this->api_signature = trim($this->_method->api_signature); $this->api_password = trim($this->_method->api_password); } if (empty($this->api_login_id) || empty($this->api_signature) || empty($this->api_password)) { $text = tsmText::sprintf('VMPAYMENT_PAYPAL_CREDENTIALS_NOT_SET', $this->_method->payment_name, $this->_method->virtuemart_paymentmethod_id); vmError($text, $text); } }