'Visa', 'MasterCard' => 'Mastercard', 'Amex' => 'American Express', 'Discover' => 'Discover', 'JCB' => 'JCB', 'DinersClub' => 'Diners Club'); // +-- // | THERE IS NO NEED TO EDIT THE CODE BELOW THIS POINT TO // | ACTIVATE THIS INTEGRATION. ONLY EDIT THIS CODE TO MODIFY // | HOW THIS INTEGRATION WORKS. BE SURE YOU KNOW WHAT YOU'RE // | DOING! // +-- // +-- // | Get a few global variables. // +-- $eol = $this->globals('core.eol'); $order = $this->globals('ecom.order_summary'); // +-- // | Set up the olpform array. // +-- $olpform = array('namespace' => 'gwprocinternal', 'button' => 'Submit Payment', 'gateway' => $order['gateway']['id'], 'orderid' => $order['order']['id'], 'gwurl' => 'https://payflowpro.paypal.com', 'fields' => array()); // +-- // | Create the HIDDEN fields for the form. // +-- $olpform['fields']['HIDDEN'][] = array('name' => 'LOGIN', 'value' => $order['gateway']['userid']); $olpform['fields']['HIDDEN'][] = array('name' => 'VENDOR', 'value' => $vendor); $olpform['fields']['HIDDEN'][] = array('name' => 'PARTNER', 'value' => $partner); $olpform['fields']['HIDDEN'][] = array('name' => 'USER1', 'value' => $order['order']['id']); $olpform['fields']['HIDDEN'][] = array('name' => 'CUSTID', 'value' => $this->globals('core_session.sid')); $olpform['fields']['HIDDEN'][] = array('name' => 'AMOUNT', 'value' => $order['order']['ordertotal']); $olpform['fields']['HIDDEN'][] = array('name' => 'FIRSTNAME', 'value' => $order['order']['fname']); $olpform['fields']['HIDDEN'][] = array('name' => 'LASTNAME', 'value' => $order['order']['lname']); $olpform['fields']['HIDDEN'][] = array('name' => 'ADDRESS', 'value' => $order['order']['addone'] . ' ' . $order['order']['addtwo']); $olpform['fields']['HIDDEN'][] = array('name' => 'CITY', 'value' => $order['order']['city']); $olpform['fields']['HIDDEN'][] = array('name' => 'STATE', 'value' => $order['order']['stateabbus']); $olpform['fields']['HIDDEN'][] = array('name' => 'COUNTRY', 'value' => $order['order']['countryabb']); $olpform['fields']['HIDDEN'][] = array('name' => 'ZIP', 'value' => $order['order']['postalcode']); $olpform['fields']['HIDDEN'][] = array('name' => 'PHONE', 'value' => $order['order']['phone']); $olpform['fields']['HIDDEN'][] = array('name' => 'EMAIL', 'value' => $order['order']['email']); // +-- // | Create the DISPLAY fields for the form. // +-- $olpform['fields']['DISPLAY'][] = array('type' => 'SELECTCUSTOM', 'params' => array('name' => 'CARDTYPE', 'required' => 1, 'display' => 'Card Type', 'desc' => 'Select the type of credit card you wish to use.', 'options' => $accepted_cards)); $olpform['fields']['DISPLAY'][] = array('type' => 'TEXTCUSTOM', 'params' => array('name' => 'CARDNUM', 'required' => 1, 'display' => 'Card Number', 'desc' => 'Enter your credit card number.')); $olpform['fields']['DISPLAY'][] = array('type' => 'TEXTCUSTOM', 'params' => array('name' => 'CVV2', 'required' => 0, 'display' => 'Card Verification Number', 'desc' => 'Enter your card verification number. Some cards do not contain verification numbers. Use the image presented below to locate your verification number.')); $olpform['fields']['DISPLAY'][] = array('type' => 'EXPTWOFIELDS', 'params' => array('mname' => 'EXPDATEM', 'yname' => 'EXPDATEY', 'required' => 1, 'display' => 'Card Expiration Date', 'desc' => 'Select the month and year your card expires from the list.', 'mformat' => 'MM', 'yformat' => 'YY')); // +-- // | Set a global variable to display the card verification // | number image. // +-- $this->globals('ecom.olp_showimg_cvv2',1); // +-- // | Globalize the $olpform array and return. // +-- $this->globals('ecom.olpform',$olpform); ?>