function process_button() { global $order, $SID; $SID = twe_session_name() . '=' . twe_session_id(); $mid = MODULE_PAYMENT_ECPAY_MID; $price = round($order->info['total']); $address = $order->customer['state'] . $order->customer['city'] . $order->customer['street_address']; if (MODULE_PAYMENT_ECPAY_RETUREURL != '') { $reurl = 'returl'; $returl_var = MODULE_PAYMENT_ECPAY_RETUREURL; } $ordnum = date('Ymdhis'); $process_button_string = twe_draw_hidden_field('client', $mid) . twe_draw_hidden_field('amount', $price) . twe_draw_hidden_field('訂購人', $order->customer['firstname']) . twe_draw_hidden_field('聯絡電話', $order->customer['telephone']) . twe_draw_hidden_field('送貨地址', $address) . twe_draw_hidden_field('email', $order->customer['email_address']) . twe_draw_hidden_field('郵遞區號', $order->customer['postcode']) . twe_draw_hidden_field('roturl', twe_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL')) . twe_draw_hidden_field('od_sob', $ordnum) . twe_draw_hidden_field('systemtype', 'twe2.2_ecpay'); return $process_button_string; }
function process_button() { global $order, $SID; $SID = twe_session_name() . '=' . twe_session_id(); $mid = MODULE_PAYMENT_GWPAYIBON_MID; $price = round($order->info['total']); if ($price <= 25) { echo "<Script Language=Javascript>\r\n\t\t\t\t\talert('綠界 7-11 iBon 付款, 最低付款金額為 35 元,按下確定後會返回購物車');\r\n\t\t\t\t\tlocation(history(-1));\r\n\t\t\t\t </script>"; exit; } $address = $order->customer['state'] . $order->customer['city'] . $order->customer['street_address']; if (MODULE_PAYMENT_GWPAYIBON_RETUREURL != '') { $reurl = 'returl'; $returl_var = MODULE_PAYMENT_GWPAYIBON_RETUREURL; } $ordnum = date('Ymdhis'); $process_button_string = twe_draw_hidden_field('client', $mid) . twe_draw_hidden_field('amount', $price) . twe_draw_hidden_field('訂購人', $order->customer['firstname']) . twe_draw_hidden_field('聯絡電話', $order->customer['telephone']) . twe_draw_hidden_field('送貨地址', $address) . twe_draw_hidden_field('email', $order->customer['email_address']) . twe_draw_hidden_field('郵遞區號', $order->customer['postcode']) . twe_draw_hidden_field('roturl', twe_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL')) . twe_draw_hidden_field('od_sob', $ordnum) . twe_draw_hidden_field('systemtype', 'twe2.3_ibonpay'); return $process_button_string; }