Example #1
0
         $body .= "\n{$key}: {$value}";
     }
     $body .= "\n\n" . __('Regards, Your friendly automated response.', 'eshop') . "\n\n";
     $headers = eshop_from_address();
     $to = apply_filters('eshop_gateway_details_email', array($bank['email']));
     wp_mail($to, $subject, $body, $headers);
     /* ############### */
     $p = new bank_class();
     if ($eshopoptions['cart_success'] != '') {
         $ilink = add_query_arg('eshopaction', 'success', get_permalink($eshopoptions['cart_success']));
     } else {
         die('<p>' . $derror . '</p>');
     }
     $p->bank_url = $ilink;
     // bank url
     $echoit .= $p->eshop_submit_bank_post($_POST);
     //$p->dump_fields();      // for debugging, output a table of all the fields
     break;
 case 'process':
     // Process and order...
     /****** The order has already gone into the database at this point ******/
     //goes direct to this script as nothing needs showing on screen.
     $p->add_field('shipping_1', eshopShipTaxAmt());
     $sttable = $wpdb->prefix . 'eshop_states';
     $getstate = $eshopoptions['shipping_state'];
     if ($eshopoptions['show_allstates'] != '1') {
         $stateList = $wpdb->get_results("SELECT id,code,stateName FROM {$sttable} WHERE list='{$getstate}' ORDER BY stateName", ARRAY_A);
     } else {
         $stateList = $wpdb->get_results("SELECT id,code,stateName,list FROM {$sttable} ORDER BY list,stateName", ARRAY_A);
     }
     foreach ($stateList as $code => $value) {
Example #2
0
         $body .= "\n{$key}: {$value}";
     }
     $body .= "\n\n" . __('Regards, Your friendly automated response.', 'eshop') . "\n\n";
     $headers = eshop_from_address();
     $to = apply_filters('eshop_gateway_details_email', array($bank['email']));
     wp_mail($to, $subject, $body, $headers);
     /* ############### */
     $p = new bank_class();
     if ($eshopoptions['cart_success'] != '') {
         $ilink = add_query_arg('eshopaction', 'success', get_permalink($eshopoptions['cart_success']));
     } else {
         die('<p>' . $derror . '</p>');
     }
     $p->bank_url = $ilink;
     // bank url
     $echoit .= $p->eshop_submit_bank_post($espost);
     //$p->dump_fields();      // for debugging, output a table of all the fields
     break;
 case 'process':
     // Process and order...
     /****** The order has already gone into the database at this point ******/
     //goes direct to this script as nothing needs showing on screen.
     $p->add_field('shipping_1', eshopShipTaxAmt());
     $sttable = $wpdb->prefix . 'eshop_states';
     $getstate = $eshopoptions['shipping_state'];
     if ($eshopoptions['show_allstates'] != '1') {
         $stateList = $wpdb->get_results("SELECT id,code,stateName FROM {$sttable} WHERE list='{$getstate}' ORDER BY stateName", ARRAY_A);
     } else {
         $stateList = $wpdb->get_results("SELECT id,code,stateName,list FROM {$sttable} ORDER BY list,stateName", ARRAY_A);
     }
     foreach ($stateList as $code => $value) {