Displaying Payment Gateway Logos in CubeCart V5 Checkout

Displaying Payment Gateway Logos in CubeCart V5 Checkout.

One fairly simple but often requested modification for older CubeCart versions (V3 and V4) was to be able to display a small logo for each enabled payment gateway in the checkout process. Shown below is the way to achieve this with CubeCart V5 – it does require (as of CubeCart V5.2.1 which is the latest at the time of this post) one very small change to a core file but we are hoping that this will be changed in the future release so even this small code change is no longer required.

CubeCart Core File Change

Edit classes/sanitize.class.php and on line 30 change

[code language=”html”]private static $exempt = array(‘description’, ‘offline_content’, ‘doc_content’,’content_html’, ‘content_text’, ‘cat_desc’, ‘copyright’, ‘maillist_format’, ‘store_copyright’, ‘htaccess-data’);[/code]

to

[code language=”html”]private static $exempt = array(‘desc’, ‘description’, ‘offline_content’, ‘doc_content’,’content_html’, ‘content_text’, ‘cat_desc’, ‘copyright’, ‘maillist_format’, ‘store_copyright’, ‘htaccess-data’);[/code]

Change in Admin Control Panel

Then you are able to add very simple html code to the payment gateway description field in order to display the image – an example to add the logo to PayPal :

In Admin | Modules | Payment Gateways option edit the PayPal gateway and add the following to the description field – this is ideally put at the start of the description and before any text used to describe the payment method.

[code language=”html”] PayPal[/code]

Below is an example of how it looks on a customer payment gateway choice page in the checkout where logos have been added to a number of different gateways :

CubeCart V5 Payment Gateway Logos

The following two tabs change content below.
This is the main Havenswift Hosting company account that is used by different members of staff when making blog postings on behalf of the company rather than as individuals

There Are 4 Comments

John on 11 May, 2013

Thanks for this posting, upgraded to cubecart V5 from V4 a month ago and used to have this on my old store so this was exactly what I was looking for !

I am still on 5.2.1 and thinking of upgrading to 5.2.2 now it has been released – do you know if the change to the core file was included yet ?

Havenswift Hosting on 11 May, 2013

Hi John

Great that you found our posting and that it was helpful !

The change wasn’t added to 5.2.2 and havent heard when / if it will be added so after upgrading, you will need to make that small change again manually.

We did log this as a suggestion in the old CubeCart Bug Tracker but this has been withdrawn from use so there is no immediate way to see whether this has been fixed and if so in which version ! If we hear anything directly from the CubeCart team, then we will update this post again

John on 08 Oct, 2013

Now that CubeCart 5.2.3 has been released, can you tell me whether this change has been made to the core code or do I still need to make the change after upgrading

Havenswift Hosting on 08 Oct, 2013

Hi John

This wasnt included in CubeCart 5.2.3 and also hasnt been included in today’s 5.2.4 release either. Unfortunately the public CubeCart Bug Tracker has been taken offline so there is no way to publicly track whether this is scheduled to be done or not in a future version. We will try and contact the developers to see if we can get an answer

Post Your Comment

Your email address will not be published. Required fields are marked *

Copyright Havenswift Hosting 2007-2020. All rights reserved.