When starting his online store Prestashop or when you're a small shop, there is often little or no interest to contract a merchant account with your bank to offer payment by credit card. The simple solution is to implement only the payment by Paypal (you pay as a commission only if you sell), which is default by PrestaShop.

The problem is that some people, particularly businesses, do not want to open a Paypal account to make purchases on the Internet. We will show you how to enable your customers to pay by credit card (CB) without opening a Paypal account, your PrestaShop store.

The module provides with Paypal Prestashop allows two types of payment:

  • The first payment by Paypal.
  • The second, less known, is to pay with credit card directly without creating a Paypal account.

The problem is that with the module provides with Paypal Prestashop, you only have one choice: "Pay with Paypal".
A client who does not have a Paypal account (and not wanting), who was not aware that you can pay directly with his credit card on Paypal, surely abandon his basket. And you have lost them.

We will see how to modify the module to get a second choice "Pay Card, Visa, Discover ..." and when we will click on this option, see an explanation (no popup) to indicate to client how to proceed with payment by credit card directly without Paypal account.

Indeed, when a customer wants to pay directly by credit card on Paypal, it does not necessarily fall on the page for that. It may well fall on a login page. Only a small link at the bottom left allows access to the payment page directly. This is done according to the presence of a cookie or not this Paypal on the machine.
It is therefore necessary to display a small help to guide the client.
You can see the results on our online store with the following catches:

PrestaShop Paypal accept payment by credit card directly


PrestaShop Paypal payment help Credit Card

Recognizing that the approaches that we describe are not always simple, modified and translated the module is available on our shop for 10 € all included.

In any case, our team can not be held responsible if the module you are going to change no longer works. Remember to make backups!

Added option "payment by credit card" module Pal

We will modify the appearance of the module Paypal. Go therefore into the folder "modules" of your installation Prestashop, and open the file Paypal.tpl.
At the beginning of the file, you will find a first marker </ p>. This corresponds to the option "Pay with Paypal".

To add a second, we will follow this tag.

Add

<p class="payment_module">

</ P>

Inside this tag, create a link with an image of your choice.

<a title="{ls='Pay by credit card (Visa, MasterCard, Aurore…)' mod='paypal'}">
<img src="{$module_template_dir}paypal-cb.jpg" alt="{ls='Pay by credit card (Visa, MasterCard, Aurore…)'}" />
(Ls = 'Pay by credit card (Visa, MasterCard, Aurora ...)' mod = 'paypal')
</ A>

Then inside the link, we'll create a call Javascript to display help (we'll create later).

onClick = "javascript :$('# helpPaypal '). slideToggle (' slow ');"

This call, use the Jquery framework (loaded by default in Prestashop). When we will click on the option, it will display with a transparent effect, help.
The # helpPaypal is an identifier for the part helps, you can change, but think of the note.

The parts containing the code type: "(ls = 'text')" are the texts to be displayed by the module. You can then translate them into the administration interface Prestashop.

Design assistance

We will now create the part that displays the user help.
Just before the tag "form" and just after the second option, create a div in which you put the ID previously returned the call Javascript.

<div id="helpPaypal">
</ Div>

To make the div, more attractive, we apply a style, with a border in "dots".

Important: You must think to apply a style that aid does not appear at all times.

<div id="helpPaypal" style="display:none;border:1px dotted">
</ Div>

Inside the div we will add two buttons, one above and one below, to go to payment (important!).

<Input type = "submit" onclick = "javascript :$('# paypal_form '). Submit ()" class = "button" style = "margin: 10px 400px;" value = "(ls =' Checkout 'mod = 'paypal') "/>

It is the onClick attribute that can do that with the value "javascript :$('# paypal_form '). Submit ();"

Finally inside the div there are plenty more to add pictures explaining the procedure and the text. It is important to explain to the client, it can fall on a page that does not allow for payment by credit card and you need to click on the link "continue" at the bottom left of the page.

For this you can use tags <img src="" alt="" /> and text p> (ls = 'mod =' paypal ') </ p>.

Translation of the modules

You've added different phrases needed to help and the new option. It'll just bring them to your unit will be available in French and in all other languages.
For this appointment in the administration of PrestaShop, then "Tools> Translations".
In the first field, choose "Modules" then click the French flag.


Prestashop translation module

It'll just find the module Paypal and to make this possible.

Conclusion

Now when you make a purchase, you should get a new option. When you click once on it, should receive assistance with two buttons to switch to payment.
This change will allow you not to lose customers without PayPal accounts and will allow you to switch from one module card, at least initially.

Aware that the steps we describe are not always simple, modified and translated the module is available on our shop for 10 € all included.

    Articles on the same subject:

  1. Prestashop configure and install the PayPal Feel free to subscribe to RSS feed to never miss any article.Même if today, the majority of consumers on the Internet using credit card, some customers are timid when to seizure of bank, especially ...
  2. Podcast team Magento Install an e-commerce without difficulties, Google Verify: Improving referencing Prestashop Feel free to subscribe to the RSS feed to never miss any article.Interview Magento Team A podcast from the interest we team's blog Metycea. They met Yoram Elalouf and Yoav Kutner Magento. You ...

49 comments why do not leave yours?

Hop hop, anything I say, I checked the box in Sandbox mode Prestashop, thus redirecting me to this page ;)

Cherry August 9, 2010 at 9 am 45 min

Hello
The module is compatible with all versions of PrestaShop. You probably have made a mistake somewhere ...

Magavenue 2 August 2010 to 22 h 53 min

Hello I turn in 1.2.5
I did the above but if modif shown in Phase I pay a blank page that opens.
are the modif it for 1.2.5??
thank you for your responses.

absolutglisse 31 July 2010 to 20 h 50 min

Thank you to read the comment just below yours.
Question already asked. The module works fine on 1.3.1. If you buy this module, you must take Prestashop version 1.3.

If you did it yourself, you made a mistake somewhere.

Magavenue July 18, 2010 at 18 H 28 min

No longer works on version 1.3.1

Come on order.php

F4brice 18 July 2010 to 16 h 48 min

Write comment