Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

currency dependent payment options


ladym

Recommended Posts

Posted

I need some help to figure out how to make the payment currency depended.

 

My default curency is pesos which is fine for bank or check payment, however paypal does not support it, so what I need is that the option to pay with paypal only shows when the customer selects dolars as the currency.

Posted

open your catalog\includes\modules\payment\paypal.php

 

locate this code:

// class constructor
function paypal() {
  global $order;

 

change it to

// class constructor
function paypal() {
  global $order, $currencies, $currency;

 

Locate this code

	  $this->form_action_url = 'https://secure.paypal.com/cgi-bin/webscr';

right below it add:

	  if( function_exists('tep_customer_greeting') ) {
	if ($currency != 'USD' ) {
	  $this->enabled = false;
	}
  }

Posted

sorry this reply is a little late, I was away for a few days. :blush:

 

thank you so very much so simple yet I would not have been able to do it without you. :thumbsup:

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...