dansken Posted March 6, 2004 Share Posted March 6, 2004 Hi All, I'm a newbie to this package. I like it and I'm getting ready to launch our site. I'm using the AIM 1.4 contribution (http://www.oscommerce.com/community/contributions,1453) which works great if you are using Authorize.net and want to capture the CVV code. Now to my problem. I've been asked to add a dropdown menu with the cards that we accept on the checkout payment page. The purpose for this is to validate the the customer chooses Visa if the card number is a Visa card number. I relize that the card number is matched up to a card type in cc_validation.php, and what I have in mind is to match the result from cc_validation to the entry on the drop down. Unfortunatley I don't have any ideas on how to accomplish this. I've written the code that creates the dropdown: ? $card_type = array(); ? $card_type[] = array('text' => 'American Express'); ? $card_type[] = array('text' => 'Discover'); ? $card_type[] = array('text' => 'Master Card'); ? $card_type[] = array('text' => 'Visa'); ? ? $image = './images/cards_color.gif'; ? ? $selection = array('id' => $this->code, ? ? ? ? ? ? ? ? ? ?'module' => $this->title ?. ' ' . '<img src=' . $image . '>', ? ? ? ? ? ? ? ? ? ? 'fields' => array(array('title' => MODULE_PAYMENT_CREDIT_CARD_TYPE, ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 'field' => tep_draw_pull_down_menu('credit_card_type', $card_type)), ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? array('title' => MODULE_PAYMENT_AUTHORIZENET_TEXT_CREDIT_CARD_OWNER, ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 'field' => tep_draw_input_field('authorizenet_cc_owner', $order->billing['firstname'] . ' ' . ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$order->billing['lastname'])), ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? array('title' => MODULE_PAYMENT_AUTHORIZENET_TEXT_CREDIT_CARD_NUMBER, ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 'field' => tep_draw_input_field('authorizenet_cc_number')), ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? array('title' => MODULE_PAYMENT_AUTHORIZENET_TEXT_CREDIT_CARD_EXPIRES, ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 'field' => tep_draw_pull_down_menu('authorizenet_cc_expires_month', $expires_month) . ' ' . tep_draw_pull_down_menu('authorizenet_cc_expires_year', ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$expires_year)), ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? array('title' => 'CVV number ' . ' ' .'<a href="javascript:popupWindow(\'' . tep_href_link ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?(FILENAME_POPUP_CVV) . '\')">' . TEXT_CVV_LINK . '</a>', ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 'field' => tep_draw_input_field('cvv','',"SIZE=4, MAXLENGTH=4")))); Does anyone have any idea on how to make this work. Any help/ideas are greatly apreciated. Thanks, Magnus Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.