Products     Magento Extension     PCI-Shopping-Carts     Templates       CRELoaded     WordPress Modules     osCommerce Modules       osCommerce Addons       osCommerce Features       osCommerce Management       Payment Modules     CRELoaded Modules       CRE Loaded Addons       CRE Loaded Features       CRE Loaded Management       Payment Modules       CRELoaded Services
Free Stuff
Customization
Templates
Compare Products
You have no items to compare.
Affiliate Info
Affiliate Program FAQ
Affiliate Log In
Recent Orders
Hot Keywords: Order Notification, Order Search, Coupon, Flash Board, Compare, Floating Message, Tracking, Moneris, RSS, Visitor Filter

  External Order Id Generator

The following osCommerce contribution is a free Opensource code originated from official osCommerce website and provided for your reference only, you may download the original contribution file(s) and install it on your own; or you may request a Paid Installation Service from Agents Of Power; Agents Of Power does the "AS IS" installation on your website, we do not guarantee it will work properly on your website. Extra Paid service is available for repairing the problem from the original contribution or from your website.
There are situations where the order_id is needed to be sent with the transaction
request to the payment processor. However, osCommerce only generates the order_id
after the payment module executes.

This contribution addresses this issue by adding a new orders_id table to the osCommerce
database and adding functions to generate the necessary orders_id and associate it with
the session when the payment module executes rather than waiting until the orders record
is created. Since this problem really only affects payment modules that require an orders_id
to pass to a gateway (such as most credit card modules do) simply the checkout_process.php file
is modified to call this new orders_id generation function for all other (non-credit card) modules,
providing backward compatibility so that changes to other payment modules are not necessary.

Any credit card module could also use this code by just adding two lines of code to the file.
The first line is the call to create a new unique orders_id ($new_order_id = tep_get_Order_ID(tep_session_id());)
and the second call clears the session field (tep_clear_Order_ID(tep_session_id());) [See the Cynergy Payment module for an
example] in the newly created orders_id record and session global in the event the card transaction is
declined so the the orders_id will be reused for a future order. This eliminates "holes" or missing
invoice numbers in the osCommerce orders database whenever a card transaction is declined. If the transaction is
approved by the gateway, nothing more needs to be done as the modifications to the order.php class handles all of the
cleanup for successful transactions.

* Please read the readme.txt file included in the package for installation instructions.

By Kirkham Systems - Joseph Farhat
3000 Old Greenwood Rd
Fort Smith, AR 72903
www.kirkhamsystems.com
   Posted on: 12/17/2008     See contribution details Request Installation with Paid service