osCommerce
osCommerce is a platform developed in PHP that ease the creation of an online store. To let your clients pay with PayU from your website, you need to install the plugin for osCommerce, which integrates PayU Latam as a valid payment gateway. For more information about osCommerce, refer to their official website.
Prerequisites
- You need an active account in PayU Latam.
- Having installed osCommerce version 2.3.
- Having the PayU’s osCommerce plugin downloaded and stored in an accessible location. Click here to download it.
Installation
Follow the next procedure to install the plugin on your website.
- Unzip the plugin file in a location of your choice. From now on, we will refer this location to
[PLUGIN_PATH]
.
In this path, you find the folderoscommerce-plugin-1.0
.
- Either using FTP or logging in as an Administrator to the server where osCommerce is installed, include the plugin files in the server as follows:
- In the server path
/[server]/apache/[publication_path]/oscommerce/catalog
, copy the plugin filesconfirmation_payu.php
andresponse_payu.php
. These files are located in the path[PLUGIN_PATH]\oscommerce-plugin-1.0\oscommerce-payu-latam-1.0\catalog
.
-
In the server path
/[server]/apache/[publication_path]/oscommerce/catalog/includes/languages/english/modules/
, copy the plugin file‘payu_latam.php
located in the path[PLUGIN_PATH]\oscommerce-plugin-1.0\oscommerce-payu-latam-1.0\catalog\includes\languages\english\modules\payment
.
Repeat this step for Spanish and Portuguese if you have them installed in your osCommerce website. These files are located in the paths:- ES:
[PLUGIN_PATH]\oscommerce-plugin-1.0\oscommerce-payu-latam-1.0\catalog\includes\languages\espanol\modules\payment
- PT:
[PLUGIN_PATH]\oscommerce-plugin-1.0\oscommerce-payu-latam-1.0\catalog\includes\languages\portugues\modules\payment
Note
PayU Latam plugin for osCommerce is only available for English, Spanish and Portuguese.
- ES:
-
In the server path
/[server]/apache/[publication_path]/oscommerce/catalog/includes/modules/payment/
, copy the plugin file‘payu_latam.php
located in the path[PLUGIN_PATH]\oscommerce-plugin-1.0\oscommerce-payu-latam-1.0\catalog\includes\modules\payment
. This file is not the same file than the one mentioned before.
- In the osCommerce admin panel, expand the Modules menu in the left panel and select Payment option.
- In the Payment section, click Install Module button located at the top right corner.
- Find the
Payu Latam
plugin and click it. Then, click Install Module button in the right panel.
- After installing the plugin, the list of installed modules of the
Payu Latam
plugin appears in the right panel.
Configuration
- In the Payment section, select the Payu Latam payment method and click the Edit button in the right panel.
- The following configuration form appears:
Configure it using the information of your PayU account as follows:
Field | Value |
---|---|
Enable / Disable | Select True to enable the payment gateway in osCommerce. |
Merchant ID | ID of your commerce in PayU Latam |
Account ID | ID of the PayU account according to the country where you want to sell. |
API key | Unique key of your commerce, you can find this key in the PayU module. |
Gateway URL | Gateway URL. For test, you can use https://sandbox.gateway.payulatam.com/ppp-web-gateway and for production https://gateway.payulatam.com/ppp-web-gateway/ |
Transaction Mode | Select Test if you want to process in the Test environment. Otherwise, select Live. |
Response page | URL of the response page. By default, the URL is http://your.domain.com/yourOscommerceFolder/catalog/response_payu.php, you must replace http://your.domain.com with your site’s domain. |
Confirmation page | URL of the confirmation page. By default, the URL is http://your.domain.com/yourOscommerceFolder/catalog/confirmation_payu.php, you must replace http://your.domain.com with your site’s domain. |
-
Save the changes using the button at the bottom of the panel.
-
Finally, expand the Localization menu and click Order Status. Verify that the order status were created according to the installed languages (English, Spanish, and Portuguese) in your osCommerce website.
The valid states are:
- For English:
Approved
,Rejected
,Failed
, andPending
. - For Spanish:
Aprobada
,Rechazada
,Fallida
, andPendiente
. - For Portuguese:
Aprovado
,Recusada
,Falha
, andPendente
.
Note
If you don’t have any of the languages mentioned before, the states does not appear in the list. If you want to install a language later, you can create these states manually using the same names displayed above.At this point, your customers can pay with PayU Latam when they do the checkout in the osCommerce’s shopping cart.