Jump to content

Force customers to choose a payment method


Bev

Recommended Posts

HI

 

I have 3 payment methods - Cheque / Bank Transfer, my merchant credit card gateway and PayPal.

I cannot figure out how to remove the check from the radio button from PayPal, it seems to grab the default.  I am using the PayPal Commerce plugin (not that I have a choice anymore, all the 3 PayPal Plugins go to the same page).  I have not fiddled with any code yet as I don't want to break my shop, but I am thinking it's in /content.checkout.php somewhere?

It seems to me that PayPal are trying to take over and at their rates for a credit card, I would soon go bust!

 

I think if no radio buttons are selected, at least the customer could make the choice and if they forget, then an error message will reminded them?

 

Link to comment
Share on other sites

These modules may have a setting called 'Position". If the Position setting is visible, you can enter a number where '1' is of a higher position in the list as compared to another module that has '5' as the position (for example). The PayPal Commerce module does not expose this setting, but rather it is present in the code.

In PayPal Commerce file /skin/admin/index.tpl, near the bottom, is a series of <input type="hidden"> tags. One <input> has a name="module[position]" with a value of "1". Change this to a value of "99". See if the PayPal choice is now at the bottom of the list and is not pre-selected.

There is also a module's setting to be the 'Default' choice, but I find nothing in the code that manages this setting. Therefore, I am curious about what you say that PayPal Commerce is 'pre-selected' in the radio-button list.

Link to comment
Share on other sites

As it happens, the name of the plugin/gateway seems to manage the position - or at least it does with Bank Transfer...  Before I try any changes, here is how PayPal appears on my page - as you see, the radio button is selected.  I took this screen shot using a browser that had never been to my website before, so it's not a browser cache problem .

paypal-problem.png

Link to comment
Share on other sites

OK have tried changing PayPal from 1 to 99 and back again.  I can move the other two with Priority boxes - the Description only changed the position because they were both set to 1 😳

I am happy for PayPal to be at the bottom - I just don't want it selected automatcally... must be an 'un' to add to be the beginning of a 'checked' somewhere!

Link to comment
Share on other sites

Hmm.

Looking through the PayPal Commerce code again, I find that in the module's file /hooks/class.cubecart.display_gateways.php, there is some code that sets $gateway[99] -- that is not related to 'position' -- to have a 'default' array element of true.

You can change that to read:

// 'default' => true

 

Link to comment
Share on other sites

I thought that was the problem. PayPal acquiring a default parameter which then had CubeCart telling the template that this choice is to show as being pre-selected.

You are saying the radio button for PayPal is still selected?

Allow me to ask, after having made the edit to the PayPal file, are you simply having the browser re-fetch the checkout page?

If so, we recommend that you empty the basket, followed by re-visiting the product page, and re-adding the product back into the cart. Then go to the checkout page.

 

Link to comment
Share on other sites

The default checking went to the Bank Transfer (despite not having the default box checked).  When I disabled the Bank Transfer gateway, both PayPal and Credit Card aquirer had a radio button UNchecked.  Will uninstall the transfer one, clear cache and reinstall it and see if that works.  Thanks for the help!

Link to comment
Share on other sites

  • 4 months later...
On 12/3/2021 at 9:30 PM, Evelyn said:

Hi Bev...where did you find the option for etransfer?   Thank you

Login to admin panel Extentions)Marketplace Find the mrnu at top of page cslled Extentions Left click Payment Gateways) ePayment interact eTrsnsfer Then download that extetion to storeClick lightning bold next to download symbol to get auto install token Vooy token link Goback to Extentions)Manage Extentikns Paste token link into feild with x's and left Go button Then enable and configure extention Then left click Clear Cache button Your Done

Link to comment
Share on other sites

There is this:

https://www.cubecart.com/extensions/shipping-methods/store-collection

It is a shipping method (sort of).

You can use this in combination with:

https://www.cubecart.com/extensions/payment-gateways/print-order-form
or
https://www.cubecart.com/extensions/payment-gateways/usa-canada-print-order-form

with the module's description being something like "Pay at Pickup".

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...