OMS DOCUMENTATIONRESOURCE CENTER

These guides provide examples for many tasks that a developer will need to be familiar with during implementation.

KIBO OMS DEVELOPMENT

Documentation

Online Order Processing

The XML Online Order Processing API allows the user to gather consumers’ order information on the client website without linking to an external URL (an Online Store). Use this API to gather a consumer’s order information in a local shopping cart and transmit it to the OMS server for order completion and fulfillment.

The Online Order Processing API allows the client to:

  • Implement or keep shopping cart solution on their server
  • Transmit order data to OMS for payment and order processing
  • Design the appearance of the shopping cart and ordering process
  • Monitor consumer orders in their own database
  • Provide a single user experience for consumers

Getting Started

System Requirements

To use the Online Order Processing API, there must be a server with Internet access that the shopping cart software can gather the order data.

Writing the Application

The client needs to write the Online Order Send application. This application gathers consumer order data from the shopping cart, generates an XML package, and uses a Remote Procedure Call (RPC) to pass this package to the OMS server. When the order data is processed in OMS, it returns a success response code. Then, the consumer can check out and complete their order.

The application can be written in any programming or scripting language that can handle an RPC, including PHP, ASP, Cold Fusion, JSP, JAVA, C, and so on.

Process Flow

The process for the Online Order Processing XML-RPC is summarized here and depicted in Figure 1:

  1. Consumer products are gathered in the merchant-side shopping cart.
  2. The shopping cart constructs a single XML package.
  3. The XML package is transmitted to OMS using the prepared RPC.
  4. A response is generated from the RPC. A single integer or cart number (cart_id) success response is returned. Alternatively, a fault response is returned, with information that identifies a problem (refer to the table with the response codes).A string store identification (store_id) is passed in to cart_id.
  5. When the cart_id is retrieved, the consumer is directed to the secure checkout process, passing the appropriate cart_id. Generally, this is done in a separate pop-up window with toolbars removed.
  6. The consumer completes the secure checkout process at the Kibo server and receives a completion screen and email.Note that the consumer is not presented with pickup locations in checkout but must make the selection and prior to checkout.
  7. The order process is now complete for the consumer and the order is sent to the OMS retailer network for fulfillment.

Programming the Online Order Processing API

Server and RPC Information

  1. Create an XML-RPC message that calls examples.loadOrder and passes a struct of the parameters shown in the table below for defining package elements.
  2. Create an XML-RPC client that connects to the following server:
    • Server file name: /xmlServer.php
    • Server address: xml.shopatron.com
    • Server port: 80 (may use HTTPS port: default is 443)
  3. On a successful response, redirect the user to www.shopatron.com/xmlCheckout1.phtml?order_id =<cart_id>, where <cart_id> is the OMS cart ID that was returned in the success response.
    • If using URL masking for checkout, replace “www.shopatron.com” with the checkout domain. For example, <checkout.mydomain.com>/xmlCheckout1.phtml?order_id =<cart_id>, where <checkout.mydomain.com> is the checkout domain, and  <cart_id> is the OMS cart ID that was returned in the success response.

Required and Optional Parameters

There are a number of possible parameters. Note that VAT clients (including all European merchants) must submit VAT-inclusive pricing to OMS and set the vat-inclusive field to 1. The promo_run_ids, ad_promo_ids, locked, or landing code elements are used if OMS is involved in shopping cart implementation.

ElementRequiredParent ElementTypeOccursDescription
(Parameter 1) mfg_id.cat_idYesNonestring1A valid and active manufacturer ID, followed by a period, followed by a valid catalog ID.
(Parameter 2) num_itemsYesNoneint1The number of items in the order.
(Parameter 3) order_dataYesNoneint1/orderOMS manufacturer ID.
item_xYesorder_datastructnThe item number. Replace x with an integer (for example, item_1, item_2, item_3, and so on).
product_idYesitem_xstring1/itemThe product ID. The maximum length is 50.
store_idOptionalItem_xstring1/itemThe ID of the store where the consumer will pick up their item. The maximum length is 100.
nameYesitem_xstring1/itemThe name of the product. The maximum length is 100.
priceYesitem_xdouble1/itemThe merchant offer price for the product.
actual_priceYesitem_xdouble1/itemThe actual price the customer is paying for the product.
avg_marginYesitem_xdouble1/itemThe average margin of the product (for example, .5 for 50%).
vat_inclusiveOptionalitem_xint1/itemValue is 1 or 0. Set to 1 if passing VAT-Inclusive pricing. VAT clients (including all European merchants) must submit VAT-inclusive pricing to OMS and set the vat-inclusive field to 1.
quantityYesitem_xint1/itemThe quantity of the product. Any promotion-run IDs associated with the item. This is a colon-separated string (for example, 12:123). Use only with ad_promo_ids. Get this ID from the OMS account manager.
promo_run_idsOptionalitem_xstring1/itemAny promotion-run IDs associated with the item. This is a colon-separated string (for example, 12:123). Use only with ad_promo_ids. Get this ID from the OMS account manager.
ad_promo_idsOptionalitem_xstring1/itemAny ad promotion IDs associated with the item. This is a colon-separated string (for example, 34:456). These should be in the same order as promo_run_ids so they correspond (for example, 12 maps to 34 and 123 maps to 456). Use only with promo_run_ids. Get this ID from the OMS account manager.
lockedOptionalitem_xint1/itemThis is a special flag for promotions where one item is free and is shipped separately by the merchant. (For example, buy a pair of shoes, get a free pair of socks.)
weightOptionalitem_xdouble1/itemThe weight of the product single item in pounds (such as 0.8, 1.2, 3.6, and so on).
cert_levelOptionalitem_xint1/itemWhen using Certification Levels, this item may be set to an integer between 0 and 9.
availabilityYesitem_xstring1/itemA single letter code that reflects the availability of an item. Y (available) is the most common value. Available values include: Y (“yes, available”), N (“not available, but may be backordered”), L (“limited availability”), M (“manufacturer ship only”), P (“preorder”), D (“discontinued, will attempt to locate stock”), I (“digital content”), J (“split to merchant”), S (“ship to store only”).
ship_typeOptionalitem_xint1/itemUsed to override the default catalog ship_type with the specified ship_type (shipping method ID). Integer <=n where n is the greatest ship_type for a non-express shipping method.
item_discount_amtOptionalitem_xdouble1/itemUsed to display the item discount amount in promotions reports when using promotions and specifically when passing a promo_run_id.
total_discountOptionalitem_xdouble1/itemUsed to display the total order discount when using promotions and specifically when passing a promo_run_id.
option_textOptionalitem_xstruct1/itemStructure that describes all options for the item.
option_xOptionaloption_textstringnThe option description. This description has two parts. The first part is a group name (such as color). This is followed by a colon. This is followed by the specific option within that option group (such as red).
(Parameter 4) Extra ParametersYesNonestruct1Unnamed holder for language_id, currency_id, landing_code, free_shipping, ip_addr, and promo_codes.
landing_codeOptionalExtra Parametersstring1A code passed by ads on other websites, like Google and Yahoo. This is used for promotion tracking.
free_shippingOptionalExtra Parametersint1A Boolean field that identifies if free shipping is to be applied to the order.
ip_addrOptionalExtra Parametersstring1The IP address that the consumer came to the site from.
promo_codesOptionalExtra Parametersstring1Any specific promotion codes that were entered at the shopping cart, separated by colons.
language_idYesExtra Parametersint1The language for the order. The following values are accepted: 1 (US English), 3 (Canadian French), 4 (UK English), 5 (DE German), and 6 (FR French).
currency_idYesExtra Parametersint1The currency type for the order. The following currency types are supported: 1 (US Dollar), 2 (Canadian Dollar), 3 (British Pound), 5 (German Euro), 6 (French Euro), 7 (Italian Euro), 8 (Spanish Euro), 9 (British Euro), 10 (Dutch Euro), 11 (Austrian Euro), 12 (Swiss Franc), 13 (Belgian Euro), 14 (Luxembourg Euro), 15 (Norwegian Krona), and 16 (Swedish Krona).

Specifying Options

Options provide size-way and color-way information on products. For each option, specify an option group name (such as color) and an option description (such as red), as indicated in this example.

<?xml version="1.0" encoding="UTF-8"?>
<methodCall>
   <methodName>examples.loadOrder</methodName>
   <params>
      <param>
         <value>
            <string>138.0</string>
         </value>
      </param>
      <param>
         <value>
            <int>1</int>
         </value>
      </param>
      <param>
         <value>
            <struct>
               <member>
                  <name>item_1</name>
                  <value>
                     <struct>
                        <member>
                           <name>product_id</name>
                           <value>
                              <string>RIB34BET</string>
                           </value>
                        </member>
                        <member>
                           <name>name</name>
                           <value>
                              <string>Super Awesome Frog</string>
                           </value>
                        </member>
                        <member>
                           <name>price</name>
                           <value>
                              <double>9.99</double>
                           </value>
                        </member>
                        <member>
                           <name>actual_price</name>
                           <value>
                              <double>9.99</double>
                           </value>
                        </member>
                        <member>
                           <name>avg_margin</name>
                           <value>
                              <double>.23</double>
                           </value>
                        </member>
                        <member>
                           <name>vat_inclusive</name>
                           <value>
                              <int>0</int>
                           </value>
                        </member>
                        <member>
                           <name>quantity</name>
                           <value>
                              <int>1</int>
                           </value>
                        </member>
                        <member>
                           <name>availability</name>
                           <value>
                              <string>Y</string>
                           </value>
                        </member>
                        <member>
                           <name>ship_type</name>
                           <value>
                              <int>11</int>
                           </value>
                        </member>
                        <member>
                           <name>option_text</name>
                           <value>
                              <struct>
                                 <member>
                                    <name>option_1</name>
                                    <value>
                                       <string>Group Name 1: Option Description 1</string>
                                    </value>
                                 </member>
                                 <member>
                                    <name>option_2</name>
                                    <value>
                                       <string>Group Name 2: Option Description 2</string>
                                    </value>
                                 </member>
                                 <member>
                                    <name>option_3</name>
                                    <value>
                                       <string>Group Name 3: Option Description 3</string>
                                    </value>
                                 </member>
                                 <member>
                                    <name>option_4</name>
                                    <value>
                                       <string>Group Name 4: Option Description 4</string>
                                    </value>
                                 </member>
                                 <member>
                                    <name>option_5</name>
                                    <value>
                                       <string>Group Name 5: Option Description 5</string>
                                    </value>
                                 </member>
                              </struct>
                           </value>
                        </member>
                     </struct>
                  </value>
               </member>
            </struct>
         </value>
      </param>
      <param>
         <value>
            <struct>
               <member>
                  <name>language_id</name>
                  <value>
                     <int>1</int>
                  </value>
               </member>
               <member>
                  <name>currency_id</name>
                  <value>
                     <int>1</int>
                  </value>
               </member>
            </struct>
         </value>
      </param>
   </params>
</methodCall>

Example Requests

This first example shows a single order with one item.

<?xml version="1.0" encoding="UTF-8"?>
<methodCall>
   <methodName>examples.loadOrder</methodName>
   <params>
      <param>
         <value>
            <string>100.1</string>
         </value>
      </param>
      <param>
         <value>
            <int>1</int>
         </value>
      </param>
      <param>
         <value>
            <struct>
               <member>
                  <name>item_1</name>
                  <value>
                     <struct>
                        <member>
                           <name>product_id</name>
                           <value>
                              <string>RC64ARF</string>
                           </value>
                        </member>
                        <member>
                           <name>name</name>
                           <value>
                              <string>SIG SUKHOI ARF KIT</string>
                           </value>
                        </member>
                        <member>
                           <name>price</name>
                           <value>
                              <double>9.99</double>
                           </value>
                        </member>
                        <member>
                           <name>actual_price</name>
                           <value>
                              <double>9.99</double>
                           </value>
                        </member>
                        <member>
                           <name>avg_margin</name>
                           <value>
                              <double>.23</double>
                           </value>
                        </member>
                        <member>
                           <name>quantity</name>
                           <value>
                              <int>1</int>
                           </value>
                        </member>
                        <member>
                           <name>availability</name>
                           <value>
                              <string>Y</string>
                           </value>
                        </member>
                     </struct>
                  </value>
               </member>
            </struct>
         </value>
      </param>
      <param>
         <value>
            <struct>
               <member>
                  <name>language_id</name>
                  <value>
                     <int>1</int>
                  </value>
               </member>
               <member>
                  <name>currency_id</name>
                  <value>
                     <int>1</int>
                  </value>
               </member>
            </struct>
         </value>
      </param>
   </params>
</methodCall>

This next request contains most of the possible elements.

<?xml version="1.0"?>
<methodCall>
  <methodName>examples.loadOrder</methodName>
  <params>
    <param>
      <value>
        <string>138.0</string>
      </value>
    </param>
    <param>
      <value>
        <int>2</int>
      </value>
    </param>
      <value>
        <struct>
          <member>
            <name>item_1</name>
            <value>
              <struct>
                <member>
                  <name>product_id</name>
                  <value>
                    <string>0000001</string>
                  </value>
                </member>
                <member>
                  <name>store_id</name>
                  <value>
                    <string>SLO Store</string>
                  </value>
                </member>                
                <member>
                  <name>name</name>
                  <value>
                    <string>Product Name 01</string>
                  </value>
                </member>
                <member>
                  <name>price</name>
                  <value>
                    <double>99.00</double>
                  </value>
                </member>
                <member>
                  <name>actual_price</name>
                  <value>
                    <double>99.00</double>
                  </value>
                </member>
                <member>
                  <name>avg_margin</name>
                  <value>
                    <double>0.5</double>
                  </value>
                </member>
                <member>
                  <name>vat_inclusive</name>
                  <value>
                    <int>0</int>
                  </value>
                </member>
                <member>
                  <name>quantity</name>
                  <value>
                    <double>1</double>
                  </value>
                </member>
                <member>
                  <name>promo_run_ids</name>
                  <value>
                    <string>333:444</string>
                  </value>
                </member>
                <member>
                  <name>ad_promo_ids</name>
                  <value>
                    <string>111:222</string>
                  </value>
                </member>
                <member>
                  <name>locked</name>
                  <value>
                    <int>1</int>
                  </value>
                </member>
                <member>
                  <name>weight</name>
                  <value>
                    <double>12.4</double>
                  </value>
                </member>
                <member>
                  <name>cert_level</name>
                  <value>
                    <int>1</int>
                  </value>
                </member>
                <member>
                  <name>availability</name>
                  <value>
                    <string>Y</string>
                  </value>
                </member>
                <member>
                  <name>ship_type</name>
                  <value>
                    <int>11</int>
                  </value>
                </member>
                <member>
                  <name>item_discount_amt</name>
                  <value>
                    <double>10</double>
                  </value>
                </member>
                <member>
                  <name>total_discount</name>
                  <value>
                    <double>10</double>
                  </value>
                </member>
              </struct>
            </value>
          </member>
          <member>
            <name>item_2</name>
            <value>
              <struct>
                <member>
                  <name>product_id</name>
                  <value>
                    <string>0000002</string>
                  </value>
                </member>
                <member>
                  <name>name</name>
                  <value>
                    <string>Product Name 02</string>
                  </value>
                </member>
                <member>
                  <name>price</name>
                  <value>
                    <double>22.00</double>
                  </value>
                </member>
                <member>
                  <name>actual_price</name>
                  <value>
                    <double>22.00</double>
                  </value>
                </member>
                <member>
                  <name>avg_margin</name>
                  <value>
                    <double>0.5</double>
                  </value>
                </member>
                <member>
                  <name>vat_inclusive</name>
                  <value>
                    <int>0</int>
                  </value>
                </member>
                <member>
                  <name>quantity</name>
                  <value>
                    <double>1</double>
                  </value>
                </member>
                <member>
                  <name>promo_run_ids</name>
                  <value>
                    <string>333:444</string>
                  </value>
                </member>
                <member>
                  <name>ad_promo_ids</name>
                  <value>
                    <string>111:222</string>
                  </value>
                </member>
                <member>
                  <name>weight</name>
                  <value>
                    <double>4.8</double>
                  </value>
                </member>
                <member>
                  <name>cert_level</name>
                  <value>
                    <int>1</int>
                  </value>
                </member>
                <member>
                  <name>availability</name>
                  <value>
                    <string>N</string>
                  </value>
                </member>
                <member>
                  <name>option_text</name>
                  <value>
                    <struct>
                      <member>
                        <name>option_1</name>
                        <value>
                          <string>Color: Blue </string>
                        </value>
                      </member>
                      <member>
                        <name>option_2</name>
                        <value>
                          <string>Size: Large </string>
                        </value>
                      </member>
                    </struct>
                  </value>
                </member>
              </struct>
            </value>
          </member>
        </struct>
      </value>
    </param>
    <param>
      <value>
        <struct>
          <member>
            <name>landing_code</name>
            <value>
              <string>AF2323IW2</string>
            </value>
          </member>
          <member>
            <name>ip_addr</name>
            <value>
              <string>72.29.175.44</string>
            </value>
          </member>
          <member>
            <name>promo_codes</name>
            <value>
              <string>EXAMPLEPROMOCODE</string>
            </value>
          </member>
          <member>
            <name>free_shipping</name>
            <value>
              <string>0</string>
            </value>
          </member>
          <member>
            <name>language_id</name>
            <value>
              <int>1</int>
            </value>
          </member>
          <member>
            <name>currency_id</name>
            <value>
              <int>1</int>
            </value>
          </member>
        </struct>
      </value>
    </param>
 </params>
</methodCall>

This example shows how to handle code that contains special character encoding; by wrapping the field into CDATA and using the HTML encoded characters.

<member> 
   <name>name</name>
   <value>
    <string><![CDATA[Öfilter Test Product R® Trade T™ ]]></string>
   </value>
</member>

Example Responses

Unlike REST APIs, the XML-RPC APIs do not return HTTP status codes to indicate success or failure. On success, the RPC returns the OMS Order Number. On an error, the RPC returns a response message with the faultCode and faultString.

A full list of faultCode and faultString options can be found below:

CodeDescription
Cart_idSuccess. All data received. OMS cart_id returned.
Fault code (Int)XML-RPC fault code (1-n).
99Error: Invalid Authorization.
2Product data not correct for load examine error message.
1Order failed to load to database.
11Error: Authorization Failure.

Successful responses may look like the below sample:

<?xml version="1.0" encoding="UTF-8"?>
<methodResponse>
   <params>
      <param>
         <value>
            <int>1234567</int>
         </value>
      </param>
   </params>
</methodResponse>

An error response includes an error code and reason:

<?xml version="1.0" encoding="UTF-8"?>
<methodResponse>
   <fault>
      <value>
         <struct>
            <member>
               <name>faultCode</name>
               <value>
                  <int>2</int>
               </value>
            </member>
            <member>
               <name>faultString</name>
               <value>
                  <string>Invalid return payload: enabling debugging to examine incoming payload</string>
               </value>
            </member>
         </struct>
      </value>
   </fault>
</methodResponse>

Handling Errors

If an error response is received fault code after sending the order information to OMS, take the following steps:

  1. Record the outgoing package and the associated fault code response from OMS.
  2. Test for connectivity to the server.
  3. Present an error screen to the consumer that states that their order is unable to be completed.
  4. Ask the consumer for the following information: First Name, Last Name, Phone Number, and Email Address.
  5. Bundle the consumer contact information and all order information, including order items quantity, and any promotions, and email the package to OMS Merchant Support

System Testing and Activation

After writing the Online Order Processing application, a testing process occurs. When tests have been completed successfully, Kibo will activate Online Order Processing for the account. Send an email to OMS Merchant Support to initiate this process. If the project is still in the Implementations phase, work with the Implementations Coordinator.

  1. Create a test order using the shopping cart.
  2. Send a test XML Order Data package by calling the RPC on the Kibo server. A response should be returned and the user should also see the first page of the checkout process. Refer to the table that lists the possible response codes.This tests the following:
    • The server can successfully communicate with Kibo’s XML-RPC server.
    • The XML Order Data package is a valid, well-formed XML document and that it includes all of the required information.
    • The application can receive all the possible response codes.

Sample Application Code (PHP)

This sample code uses XML-RPC for PHP open source libraries from http://xmlrpc.scripting.com.

Select one of the test blocks (depending on whether options are being passed) and comment out the other test block before running the script. If the script runs successfully, the response will include debugging information and an Order Number.

<?php
// these includes are shown as examples. You need to write your own database connector
// and xml_functions. The two xmlrpc include files are part of XMLRPC for PHP
  include_once("/includes/database_connect.php");
  include_once("/includes/xmlrpc.inc");
  include_once("/includes/xmlrpcs.inc");
  include_once("/includes/xml_functions.php");

  $debug = 1; // remove line or set to 0 when done testing

  /******* Simple Test Order block *******/
  $mfg_id = "138.0";
  $message = new xmlrpcmsg('examples.loadOrder',
  array(
  new xmlrpcval($mfg_id, 'string'),
  new xmlrpcval(2, 'int'),
  new xmlrpcval(
  array(
  "item_1" => new xmlrpcval(
  array(
  "product_id" => new xmlrpcval("0000001"),
  "name" => new xmlrpcval("Product Name 01"),
  "price" => new xmlrpcval(99.00, 'double'),
  "actual_price" => new xmlrpcval(99.00, 'double'),
  "avg_margin" => new xmlrpcval(0.5, 'double'),
  "vat_inclusive" => new xmlrpcval(0,'int'),
  "quantity" => new xmlrpcval(1,'int'),
  "promo_run_ids" => new xmlrpcval("333:444"),
  "ad_promo_ids" => new xmlrpcval("111:222"),
  "locked" => new xmlrpcval(1,'int'),
  "weight" => new xmlrpcval(12.4,'double'),
  "cert_level" => new xmlrpcval(1,'int'),
  "availability" => new xmlrpcval("Y"),
  "item_discount_amt" => new xmlrpcval(10,'double'),
  "total_discount" => new xmlrpcval(10,'double')
  ),
  "struct"),
  "item_2" => new xmlrpcval(
  array(
  "product_id" => new xmlrpcval("0000002"),
  "name" => new xmlrpcval("Product Name 02"),
  "price" => new xmlrpcval(22.00, 'double'),
  "actual_price" => new xmlrpcval(22.00, 'double'),
  "avg_margin" => new xmlrpcval(0.5, 'double'),
  "vat_inclusive" => new xmlrpcval(0,'int'),
  "quantity" => new xmlrpcval(1,'int'),
  "promo_run_ids" => new xmlrpcval("333:444"),

  "ad_promo_ids" => new xmlrpcval("111:222"),
  "weight" => new xmlrpcval(4.8,'double'),
  "cert_level" => new xmlrpcval(1,'int'),
  "availability" => new xmlrpcval("N"),
  "option_text" => new xmlrpcval(
  array(
  "option_1" => new xmlrpcval("Color: Blue"),
  "option_2" => new xmlrpcval("Size: Large")
  ),
  "struct")
  ),
  "struct")
  ),
  "struct")
  ),
  "array");
  /******* end Simple Test Order block *******/

  // connect with the Shopatron server
  $server = new xmlrpc_client('/xmlServer.php','www.shopatron.com', 80);
  $server->setDebug(1);// turn debug on

  // send xml package
  $result = $server->send($message);
  // alternate send specifying timeout length and protocol
  // $result = $server->send($xml_order, 30, 'https');

  // check for the result
  if(!$result && !is_numeric($result)) //the result hasn't been return or non-numeric
  {
  echo '<table align="center" width="100%" height="100%" border="0">
  <tr>
    <td align="center" class="error">
      We could not connect with the Shopatron Dealer Network Site.
      <br>
        <a href="/email_order.php">Submit Order Via Email</a>
      </td>
    </tr>
  </table>';
  }
  elseif($result->faultCode()) //the result has been returned but there is an error
  {
  if ($debug == 1)
  {
  echo "<p>XML-RPC Fault #".$result->faultCode().": ".$result->faultString();
  // To display a serialized "human readable" version of the XML payload
  // uncomment this next line.
  //echo "<BR> the serialized version of the message <PRE>".htmlentities($message->serialize()). "</PRE>";
  }
  else
  {
  // send to email order page
  Header("Location:/email_order.php");
  exit();
  }
  }
  else //the result has been returned and new window is spawned with Shopatron
  {
  $value=$result->value();
  $orderID = $value->scalarval(); // collect the order_id
  if ($debug == 1)
  {
  // dump to screen for testing only
  echo "<pre>";var_dump($value); var_dump($result); echo "</pre>";
  }
  else
  {
  // when done testing, use the following two lines to redirect the consumer
  Header("Location:https://www.shopatron.com/xmlCheckout1.phtml?order_id=$orderID");
  exit();
  }
  }

  /* // Alternate actions
  echo '<table align="center" width="100%" height="100%" border="0">
  <tr>
    <td align=center class="success">
      Your order has been successfully sent.<br>
      Your Shopatron Order ID: '.htmlentities($orderID).'
    </td>
  </tr>';

  echo "<script>window.open('www.shopatron.com/xmlCheckout1.phtml?order_id=$orderID');
  document.writeln('</table>');</script>
  <noscript>
    <font face=\"Arial\" size=\"2\" color=\"#404040\"> If you are not automatically redirected in 10 seconds, click <a href='www.shopatron.com/xmlCheckout1.phtml?order_id=$orderID' target=_blank>here</a> to continue...</font>
  </noscript>";
  */

  /*
  echo '<BR> got an order number <a href="https://www.shopatron.com/xmlCheckout1.phtml?order_id='.$orderID.'"> click here to checkout</a>';
  */