Jump to content

beauster

Members
  • Content count

    12
  • Joined

  • Last visited

1 Follower

Profile Information

  • Real Name
    Beau
  1. beauster

    One Page Checkout Support

    Hi Steve, Thanks so much for the reply. I am self teaching myself this so I think I understood your directions as removing the offending code section around 179 and pasteing it at the end of the section function pre_confirmation_check() {. It did get rid of my error, but now there are no titles or cc fields under payment section of one page checkout. Just a fill in circled button with Meritus xp payment option. My code from line 136-182 looks like: function pre_confirmation_check() { global $HTTP_POST_VARS; include(DIR_WS_CLASSES . 'cc_validation.php'); $cc_validation = new cc_validation(); $result = $cc_validation->validate($HTTP_POST_VARS['AA_PAYMENTXP_cc_number'], $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_month'], $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_year']); $error = ''; switch ($result) { case -1: $error = sprintf(TEXT_CCVAL_ERROR_UNKNOWN_CARD, substr($cc_validation->cc_number, 0, 4)); break; case -2: case -3: case -4: $error = TEXT_CCVAL_ERROR_INVALID_DATE; break; case false: $error = TEXT_CCVAL_ERROR_INVALID_NUMBER; break; } if ( ($result == false) || ($result < 1) ) { $payment_error_return = 'payment_error=' . $this->code . '&error=' . urlencode($error) . '&AA_PAYMENTXP_cc_owner_firstname=' . urlencode($HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_firstname']) . '&AA_PAYMENTXP_cc_owner_lastname=' . urlencode($HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_lastname']) . '&AA_PAYMENTXP_cc_expires_month=' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_month'] . '&AA_PAYMENTXP_cc_expires_year=' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_year']; tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, $payment_error_return, 'SSL', true, false)); } $this->cc_card_type = $cc_validation->cc_type; $this->cc_card_number = $cc_validation->cc_number; $this->cc_expiry_month = $cc_validation->cc_expiry_month; $this->cc_expiry_year = $cc_validation->cc_expiry_year; $this->cc_cvv2 = $HTTP_POST_VARS['AA_PAYMENTXP_cvv2'];$confirmation = array('title' => $this->title . ': ' . $this->cc_card_type, 'fields' => array(array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_OWNER, 'field' => $HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_firstname'] . ' ' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_lastname']), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_NUMBER, 'field' => substr($this->cc_card_number, 0, 4) . str_repeat('X', (strlen($this->cc_card_number) - 8)) . substr($this->cc_card_number, -4)), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_CVV2, 'field' => $HTTP_POST_VARS['AA_PAYMENTXP_cvv2']), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_EXPIRES, 'field' => strftime('%B, %Y', mktime(0,0,0,$HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_month'], 1, '20' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_year']))))); return $confirmation; } function confirmation() { global $HTTP_POST_VARS; } Any further ideas on how to get the cc titles (first,last name, CC, CCV, expiration) and entry fields to appear? They do appear when on page checkout is disabled. Thanks so much for your advice so far. global $HTTP_POST_VARS;
  2. beauster

    One Page Checkout Support

    I have just installed the latest version of one page checkout. I am running oscommerce 2.2, with Meritus xp payment module. The install seems to have mostly worked except when it comes to entering the cc info. There are no input boxes for cc info and I get this error on the one page checkout: Warning: str_repeat() [function.str-repeat]: Second argument has to be greater than or equal to 0 in /home/xxxxx/public_html/catalog/includes/modules/payment/aa_paymentxp.php on line 179 Meritus PaymentXP Credit Card Owner: Credit Card Number: CVV2 (3-digit # on back) Credit Card Expiration Date: December, 2019 line 172-186 are as follows: function confirmation() { global $HTTP_POST_VARS; $confirmation = array('title' => $this->title . ': ' . $this->cc_card_type, 'fields' => array(array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_OWNER, 'field' => $HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_firstname'] . ' ' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_lastname']), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_NUMBER, 'field' => substr($this->cc_card_number, 0, 4) . str_repeat('X', (strlen($this->cc_card_number) - 8)) . substr($this->cc_card_number, -4)), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_CVV2, 'field' => $HTTP_POST_VARS['AA_PAYMENTXP_cvv2']), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_EXPIRES, 'field' => strftime('%B, %Y', mktime(0,0,0,$HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_month'], 1, '20' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_year']))))); return $confirmation; } LINE 179 is: 'field' => substr($this->cc_card_number, 0, 4) . str_repeat('X', (strlen($this->cc_card_number) - 8)) . substr($this->cc_card_number, -4)), Can anybody offer any help?
  3. beauster

    Please I need help

    I have just installed the latest version of one page checkout. I am running oscommerce 2.2, with Meritus xp payment module. The install seems to have mostly worked except when it comes to entering the cc info. There are no input boxes for cc info and I get this error on the one page checkout: Warning: str_repeat() [function.str-repeat]: Second argument has to be greater than or equal to 0 in /home/xxxxx/public_html/catalog/includes/modules/payment/aa_paymentxp.php on line 179 Meritus PaymentXP Credit Card Owner: Credit Card Number: CVV2 (3-digit # on back) Credit Card Expiration Date: December, 2019 line 172-186 are as follows: function confirmation() { global $HTTP_POST_VARS; $confirmation = array('title' => $this->title . ': ' . $this->cc_card_type, 'fields' => array(array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_OWNER, 'field' => $HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_firstname'] . ' ' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_owner_lastname']), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_NUMBER, 'field' => substr($this->cc_card_number, 0, 4) . str_repeat('X', (strlen($this->cc_card_number) - 8)) . substr($this->cc_card_number, -4)), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_CVV2, 'field' => $HTTP_POST_VARS['AA_PAYMENTXP_cvv2']), array('title' => MODULE_PAYMENT_AA_PAYMENTXP_TEXT_CREDIT_CARD_EXPIRES, 'field' => strftime('%B, %Y', mktime(0,0,0,$HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_month'], 1, '20' . $HTTP_POST_VARS['AA_PAYMENTXP_cc_expires_year']))))); return $confirmation; } LINE 179 is: 'field' => substr($this->cc_card_number, 0, 4) . str_repeat('X', (strlen($this->cc_card_number) - 8)) . substr($this->cc_card_number, -4)), Can anybody offer any help?
×