PHP Fatal error: Cannot redeclare do_magic_quotes_gpc() in osCommerce Store

During osCommerce store customization and add-on installation, if you get following error Cannot redeclare do_magic_quotes_gpc(): PHP Fatal error: Cannot redeclare do_magic_quotes_gpc() (previously declared in /home/user/public_html/butikk/includes/functions/compatibility.php:19) in /home/user/public_html/butikk/includes/functions/compatibility.php on line 3 This error is caused by copying of a module file into the languages “catalog/includes/languages/” folder by mistake during some add-on installation. Check all the files…



[osCommerce] Change Currency Selection based on Payment Module on checkout_confirmation page in osCommerce Store

In osCommerce store which has been set up to accept payment using multiple payment modules, there are chances that you might want to accept payments in specific currencies based on payment methods. Not every payment method support all currencies. You can change currency based on payment module selection by adding few lines of code on…



[osCommerce] How To Check if the Customer is Logged in or not in osCommerce Store

While working in osCommerce store, there are many places where you want to show some infromation only to logged in customers, and some thing else to non-logged in users. For this purpose, you need to check tep_session_is_registered(‘customer_id’) variable and show different blocks of content. In the following code, I have put togther an example where…



[osCommerce] EasyPaisa Mobile Money Transfer Contribution for osCommerce Store

While implementing a recent osCommerce store, I needed to add Mobile Money Transfer payment as another option for the customers to pay. Requirement was quite straight forward, I needed to incorporate EasyPaisa Mobile Money Transfer provided by Telenor in Pakistan which would let customers choose it as a payment option and then make the payment…



[osCommerce] Implementing Multiple Shipping Rates for Multiple Countries/Zones in osCommerce

Shipping cost calculation is the mandatory feature for any E-Commerce website. Shipping cost is dependent upon zones and/or countries. It largely depends upon your requirement whether you need to charge different rates for different zones inside same country. You might want to do the same for multiple countries as well with or without multiple zones…



[osCommerce] How to Enable register_globals for osCommerce installation

If you get this following error after installing your osCommerce store: Server Requirement Error: register_globals is disabled in your PHP configuration. This can be enabled in your php.ini configuration file or in the .htaccess file in your catalog directory. There are two ways to enable register_globals using .htaccess file or using php.ini file. Enabling register_globals…



[osCommerce] Resolve error setting up Westpac Payway Net osCommerce module invalid IP address

While setting up Westpac – Payway Net osCommerce module on a new online store, I encountered following error while testing it: Notice: Error getting token: java.lang.SecurityException: Invalid IP address in /home/user/public_html/includes/functions/payway_utility.php on line 271   Warning: Cannot modify header information – headers already sent by (output started at /home/user/public_html/includes/functions/payway_utility.php:271) in /home/user/public_html/includes/functions/general.php on line 33 First…