Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Getting order_total for payment page


camNZ

Recommended Posts

Posted

Hi there,

 

Here is my question: I've created some code to interact with a payment client for CC validation/processing. When I get to the checkout_payment page, I would like the customer to send their details (cc_type, number, expiry, name, value etc) to my payment client/gateway for validation. I can capture all the details through the form apart from the total order value (sum of subtotal and tax).

 

How can I get this value? Im pretty sure its through the order_totals.php, but I am unsure how to extract only the total value.

 

Can anyone help,

 

Many thanks,

Campbell

Posted

Figured it out;

 

For anyones info:

 

<?php

if (MODULE_ORDER_TOTAL_INSTALLED) {

$order_totals = $order_total_modules->process();

$grandTotal = $order_totals[2]['value'];

}

?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...