Which files do I edit so I can add the paypal and sagepay logos to the payment checkout pages next to the radio check buttons instead of the text 'Paypal' and 'Credit/Debit Card (Sagepay)'?
or maybe add the logos underneath the text?
Thank you
Helen
Find:
Code: Select all
$_['text_title'] = 'Bank Transfer';
Code: Select all
$_['text_title'] = '<img src="http://www.domain.com/image/data/anz.gif" width="120" />';
Cheers, Sam
goto
/catalog/model/payment/pp_standard.php for example and change
Code: Select all
'title' => $this->language->get('text_title')
Code: Select all
'title' => $this->language->get('img_title')
/catalog/language/english/payment/pp_standard.php
and add
Code: Select all
$_['img_title'] = '<img src="' . HTTPS_SERVER . 'catalog/view/theme/default/image/payment/your_paypal_logo.png" alt="PayPal.com" title="PayPal.com" /></a>';
Go to
In 'catalog/controller/language/payment/your payment method.php' and add the following:
Find:
Code: Select all
$_['text_title'] = 'credit cards (PayPal Advanced)'
Code: Select all
$_['pay_icon'] ='<img src"' . HTTPS_SERVER . 'catalog/view/default/image/your_payment_logo.png" alt="payment text goes here" title-"payment title" /></a>';
Find:
Code: Select all
'title' => $this->language->get('text_title')
Code: Select all
'p_logo' => $this->language->get('pay_icon')
Replace :
Code: Select all
<label for="<?php echo $payment_method['code']; ?>" style="cursor: pointer;"><?php echo $payment_method['title']; ?></label></td>
Code: Select all
<label for="<?php echo $payment_method['code']; ?>" style="cursor: pointer;"><?php echo $payment_method['p_logo']; ?></label></td>
BionicBill wrote:Found a better solution works for 1.5.4
Go to
In 'catalog/controller/language/payment/your payment method.php' and add the following:
Find:Add below:Code: Select all
$_['text_title'] = 'credit cards (PayPal Advanced)'
Next find: 'catalog/model/payment/your payment type.phpCode: Select all
$_['pay_icon'] ='<img src"' . HTTPS_SERVER . 'catalog/view/default/image/your_payment_logo.png" alt="payment text goes here" title-"payment title" /></a>';
Find:Add below that :Code: Select all
'title' => $this->language->get('text_title')
Next in: 'catalog/view/theme/default/template/payment/your payment method.tpl'Code: Select all
'p_logo' => $this->language->get('pay_icon')
Replace :With this:Code: Select all
<label for="<?php echo $payment_method['code']; ?>" style="cursor: pointer;"><?php echo $payment_method['title']; ?></label></td>
Code: Select all
<label for="<?php echo $payment_method['code']; ?>" style="cursor: pointer;"><?php echo $payment_method['p_logo']; ?></label></td>
actulally the correct path is:Go to
In 'catalog/controller/language/payment/your payment method.php' and add the following:
'catalog/language/controller/YOULANGUAGE/payment/your payment method.php'
and in
I went to 'catalog/view/theme/default/template/checkout/payment_method.tpl'Next in: 'catalog/view/theme/default/template/payment/your payment method.tpl'
Replace :With this:Code: Select all
<label for="<?php echo $payment_method['code']; ?>" style="cursor: pointer;"><?php echo $payment_method['title']; ?></label></td>
Code: Select all
<label for="<?php echo $payment_method['code']; ?>" style="cursor: pointer;"><?php echo $payment_method['p_logo']; ?></label></td>
and change the line:
Code: Select all
<td><label for="<?php echo $payment_method['code']; ?>"><?php echo $payment_method['title']; ?></label></td>
Code: Select all
<td><label for="<?php echo $payment_method['code']; ?>"><?php if(isset($payment_method['p_logo'])){ echo $payment_method['p_logo'];}else{echo $payment_method['title'];} ?></label></td>
In template/checkout/payment_method.tpl use the name of the payment method in the 'template/payment' folder as the array key (left) and the name of the preferred image on the right. If the name of your payment method matches it will use the chosen image.
before
Code: Select all
<?php foreach ($payment_methods as $payment_method) { ?>
Code: Select all
<?php $logos = array(
'bank_transfer' => 'banktransfer.png',
'cod' => 'post-nl.png',
'direct_ebanking' => 'direct-ebanking.png',
'free_checkout' => 'free.jpg',
'idealcheckoutideal' => 'ideal.png',
'mistercash' => 'mistercash.png',
'moneybookers' => 'moneybookers.png',
'pp_standard' => 'paypal.png',
'pp_express' => 'paypal.png',
'sofort' => 'sofort.png',
); ?>
before
Code: Select all
<?php echo $payment_method['title']; ?>
Code: Select all
<?php foreach ($logos as $method=>$logo) {
if ($payment_method['code'] == $method) {
echo '<img src="'.HTTP_SERVER.'image/payment-icons/' . $logo . '" height="24">';
}
} ?>
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
http://www.opencart.com/index.php?route ... n_id=22915
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
Do you happen to have a copy somewhere, or better yet, an updated version for 3.0.2.0?
Thanks in advance if you do, thanks anyway for the manual solution
Exept for latest Versions, those usually don't yet come for free !
Ernie
---
Payment/Shipping Images 151 free, OC v.1.5.1.x:
https://www.opencart.com/index.php?rout ... on_id=2851
---
Payment Logo free, OC v.1.5.3.x - 1.5.6.x:
https://www.opencart.com/index.php?rout ... n_id=16173
---
Payment Logo free, OC v.1.5.5.x - 1.5.6.x:
https://www.opencart.com/index.php?rout ... n_id=14358
---
Checkout Payment Logos free, OC v.2.0.0.0 - 2.3.0.2:
https://www.opencart.com/index.php?rout ... n_id=29551
---
add icon checkout and payment icons free, OC v.2.0.1.0 - 2.1.0.1:
https://www.opencart.com/index.php?rout ... n_id=28125
---
---
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Users browsing this forum: No registered users and 85 guests