TOPIC:

Two PayPal Buttons on a form are needed, but with difference pricing offers! 4 weeks 2 days ago #253272

  • Topic Author
  • Rajneesh
  • Offline
  • Senior Breezer
  • Senior Breezer
  • Posts: 92
  • Thanks: 0
Dear Friends,

I am having a situation here. I want to address two segments here: Indians, Non-Indian and want to offer them different price.

For testing purpose & example:
Non-Indians: USD 990
Indians: INR 42000 + 7560 Tax = INR 49560

I created two Paypal buttons:
Button1
(for Non-Indians with USD 990)

Button2
(for Indians with INR 42000+7560 Tax)

Since I don't want both buttons to appear at the same time, I created an element asking them the question, "Do you live in India currently?" with default answer 'No' and other option 'Yes'.

Next, I used the feature of making element on or off based on the answer to this question. The result was that now the right button was appearing, as per the above answer.

I felt that I solved the problem.

But when I click on ANY of these buttons, it goes on the website of PayPal but asks for amount USD 990, even if the Button2 is in action...

Both buttons are firing, but leading me to same PayPal page which is asking for the same amount in USD.


This is the problem I am not able to handle...

I solicit your help in troubleshooting it.

With thanks,

RK

Please Log in or Create an account to join the conversation.

Last edit: Post by Rajneesh.

Two PayPal Buttons on a form are needed, but with difference pricing offers! 4 weeks 2 days ago #253279

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Posts: 3734
  • Karma: 3
  • Thanks: 302
Hi,

unfortunately, it is not possible to have two Paypal buttons on the same form because they won't function.
You haven't set anything wrong, that is the default behavior since only one PayPal button should be used per page.

You can create a select list for Indians and Non-Indian, and send different prices to paypal button (pass amount from select list to the paypal button).
Is this ok for you?

Regards,
Tihana

Please Log in or Create an account to join the conversation.

Two PayPal Buttons on a form are needed, but with difference pricing offers! 4 weeks 2 days ago #253286

  • Topic Author
  • Rajneesh
  • Offline
  • Senior Breezer
  • Senior Breezer
  • Posts: 92
  • Thanks: 0
Dear Tihana,

You proposed an alternative approach. I appreciate that.

Please guide me with your instructions, as how to go about that.

With thanks,

RK

Please Log in or Create an account to join the conversation.

Two PayPal Buttons on a form are needed, but with difference pricing offers! 4 weeks 2 days ago #253287

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Posts: 3734
  • Karma: 3
  • Thanks: 302
Hi,

I create a small example for you.

File Attachment:

File Name: example261.zip
File Size:9 KB

Please download->unzip and install it (BF->Configuration->Package Installer->select this xml file->Install Package)->find form in Manage forms
Here is select list with indian and non-indian values.
This values is send to total->then total value is stored to paypal.

I didn't set paypal site and secret key.

Regards,
Tihana
Attachments:

Please Log in or Create an account to join the conversation.

Two PayPal Buttons on a form are needed, but with difference pricing offers! 4 weeks 2 days ago #253300

  • Topic Author
  • Rajneesh
  • Offline
  • Senior Breezer
  • Senior Breezer
  • Posts: 92
  • Thanks: 0
Dear Tihana,

I wish to convey my sincere thanks to you.

I have collected the pieces of elements which you have shared.

Here they are:
First Element (Select from list), name: select1

List:
0;Please select;
0;Indian;42000
0;Non-indian;990

Code Framework:

function ff_select1_action(element, action)
{
    ff_getElementByName('total').value = Number(ff_getElementByName('select1').value);
} // ff_select1_action

-------------------------------------------------------------
Second Element (Textfield), name: total

Code Framework:

function ff_total_action(element, action)
{
ff_getElementByName('total').value=0;
{
  ff_getElementByName('total').value =
Number(ff_getElementByName('select1').value);
}
} // ff_total_action

-------------------------------------------------------------

Third Element (Hidden Input), name: bfPaymentSelect

Code Framework:
<no code>



-------------------------------------------------------------

Fourth Element (Paypal Button), name: PayPalButton

Code Framework:

function ff_PayPalButton_action(element, action)
{
    switch (action) {
        case 'click':
		ff_getElementByName('bfPaymentSelect').value = 'Your text here|0|' + ff_getElementByName('total').value + '|0'; 
        ff_validate_submit(); 
        break;
        default:;
    } // switch
} // ff_PayPalButton_action

-------------------------------------------------------------

I guess, we are heading in right direction...

However, I request you to please consider two-issues here.

Non-Residents: The currency is USD and value 990, but not tax here.
Indians: The currency is INR and value is 42000 with 7560 as tax making the total value 49560.

I solicit your guidance about how to accommodate CURRENCY in both cases, TAX and TOTAL VALUE in case of Indians.

Please instruct further.

With thanks,

RK

Please Log in or Create an account to join the conversation.

Two PayPal Buttons on a form are needed, but with difference pricing offers! 4 weeks 2 days ago #253304

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Posts: 3734
  • Karma: 3
  • Thanks: 302
Hi,

give me some time to test this :)
Also, there can be some problems, because we can use only one paypal button , and set one currency in Properties of paypal :/

Regards,
Tihana

Please Log in or Create an account to join the conversation.

Moderators: ForumSupport
Time to create page: 0.046 seconds

BreezingForms Pro 1.4.7 for WordPress Released!

Available in the membership section.

September Discount!

Massive discounts on all subscriptions!

Get Your Subscription Here

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Special Offer

Summer Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!