I think the code below is where the problem is.... Any help would be really appreciated.
/*
$last_order_id = $db->Execute("select * from " . TABLE_ORDERS . " order by orders_id desc limit 1");
$new_order_id = $last_order_id->fields['orders_id'];
$new_order_id = $new_order_id++;*/
$process_button_string = zen_draw_hidden_field('cmd', 'click') .
zen_draw_hidden_field('merchant', 'yoursiteref1234') .
zen_draw_hidden_field('merchantemail', '[email protected]') .//the email address you want the notifications of transactions sent to.
zen_draw_hidden_field('orderref', $order_id) . zen_draw_hidden_field('customerid', $customer_id) .
zen_draw_hidden_field('inputamount', round($order->info['total'],2)) .
zen_draw_hidden_field('name', $order->billing['firstname'].' '.$order->billing['lastname']) .
zen_draw_hidden_field('address', $order->billing['street_address'] . ', ' .$order->customer['suburb']) .//you can remove the suburb statement if you only want to show first line of address
zen_draw_hidden_field('zenid',zen_session_id()) .
zen_draw_hidden_field('town', $order->billing['city']) .
zen_draw_hidden_field('county',$order->billing['state']) .
zen_draw_hidden_field('country',$order->billing['country']['title']) .
zen_draw_hidden_field('postcode', $order->billing['postcode']) .
zen_draw_hidden_field('telephone',$order->customer['telephone']) .
zen_draw_hidden_field('email', $order->customer['email_address']) .
zen_draw_hidden_field('customeremail', '1') .
zen_draw_hidden_field('callbackurl','1') .
zen_draw_hidden_field('cancelurl', zen_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'))
;




