rince Posted March 18, 2004 Share Posted March 18, 2004 I'm trying to customise the ot_surcharge module (http://www.oscommerce.com/community/contributions,1306) so that it only adds a percentage on certain credit cards rather than applying to _all_ credit cards. My problem is that I don't know how to retrieve the credit card type as identified by classes/cc_validation.php. Ideally, there'd be something like $globalvars->cc['type'] that would contain 'visa' or 'mastercard', depending on what was chosen on the checkout_payment.php page. Is there such a thing? Thanks in advance, rince Link to comment Share on other sites More sharing options...
rince Posted March 18, 2004 Author Share Posted March 18, 2004 Okay - answering my own question somewhat (as I've seen other references to The following kind of works: $confirmation = $payment_modules->confirmation(); $cc_details = $confirmation['title']; $cc_details contains: "Credit/Debit Card: Visa" So I can split 'Visa' out of that, which gives me enough to be working on. Certainly not elegant, but it'll get the job done. I found a reference to $order->info['cc_type'] in checkout_process.php, but sadly this appears to be empty when called from within checkout_confirmation.php More elegant solutions are gratefully received. =) rince Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.