Hi, i am nearly there with gettin ubercart setup with nochex. im stuck now however and wondered if anyone could help?
I have been editing the
function uc_cart_checkout_review_form_submit()
so when the user clicks the submit order page they are forwarded to the nochex site with the details passed in the url string. here is what the function looks like at the moment:
function uc_cart_checkout_review_form_submit($form_id, $form_values) {
switch ($form_values['op']) {
case variable_get('uc_checkout_submit_button', t('Submit order')):
// Invoke hook_order($op = 'submit') to test to make sure the order can
// be completed... used for auto payment in uc_credit.module.
$order = uc_order_load($_SESSION['cart_order']);
$pass = module_invoke_all('order', 'submit', $order, NULL);
foreach ($pass as $result) {
$msg_type = 'status';
if ($result['pass'] === FALSE) {
$error = TRUE;
$msg_type = 'error';
}
if (!empty($result['message'])) {
drupal_set_message($result['message'], $msg_type);
}
}
if ($error === TRUE) {
$_SESSION['do_review'] = TRUE;
return 'cart/checkout/review';
}
else {
$_SESSION['do_complete'] = TRUE;
return 'https://www.nochex.com/nochex.dll/checkout?
email=sales@boxed.com
&amount='.'3.99'.
'&firstname='.'joe'.
'&lastname='.'blogs'.
'&email_address_sender='.'joe@bloggs.com'.
'&firstline='.'1 Street Lane'.
'&town='.'Leeds'.
'&postcode='.'LS2 7EE';
}
}
}
that passes static values to nochex and works well. But how can i pass the total price and other details from the review order page dynamically?
Any help would be great
Thanks
Andy




Joined: 03/27/2008