Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Edit Fast Lane Checkout to show images instead of text

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 09-19-2008, 01:29 PM
 
fireflight fireflight is offline
 

Member
  
Join Date: Jun 2008
Posts: 10
 

Question Edit Fast Lane Checkout to show images instead of text

I've gone through the forums and files trying to figure out how to do this.

Our client wants to replace the text on the Shipping and Payment page "modules/Fast_Lane_Checkout/checkout_2_method.tpl" with images of the credit cards or payment methods. So instead of saying "Visa, Mastercard, American Express" the $payment.payment_details variable would show the logos of those three.

The payment methods admin page lets me edit the text, but doesn't allow me to add HTML to link to the correct images for each of the payment methods. Is there any way to do this with the fast lane checkout? Or am I out of luck on this one?
__________________
Version 4.1.9
Reply With Quote
  #2  
Old 09-20-2008, 08:05 AM
  JWait's Avatar 
JWait JWait is offline
 

X-Man
  
Join Date: Nov 2005
Location: California
Posts: 2,440
 

Default Re: Edit Fast Lane Checkout to show images instead of text

Well, the payment methods are in a loop in the Fast_Lane_Checkout module, and the text is displayed using the {$payment.payment_details} variable. You can add an image in checkout _2_method.tpl, but I think you would need to add another loop with a "if" to display the "credit cards" image only where it applies, and I have no idea what the correct payment.payment_details variable is. I don't think you can get a individual image to display for each credit card easily though since it is from a pulldown menu in checkout _3_place.tpl.
__________________
Two Separate X-Cart Stores
Version 4.4.4 Gold - X-AOM - Vivid Dreams Aquamarine (modified) - Linux
Mods - Newest Products - View All -, and a few others. Numerous upgrades from 4.0.x series.
Integrated with Stone Edge Order Manager + POS

Version 4.1.12 Gold (fresh install) - X-AOM - Linux
Mods - XCSEO free
Reply With Quote
  #3  
Old 09-22-2008, 05:49 AM
 
fireflight fireflight is offline
 

Member
  
Join Date: Jun 2008
Posts: 10
 

Question Re: Edit Fast Lane Checkout to show images instead of text

I was afraid of that. The client is looking for a separate image for each payment method. Once I saw that loop, I had a bad feeling about it.

Would there be an easy way to allow HTML into the special instructions fields in the admin area? Could I edit the admin pages template/php to allow html to be added?
__________________
Version 4.1.9
Reply With Quote
  #4  
Old 09-22-2008, 09:05 AM
 
fireflight fireflight is offline
 

Member
  
Join Date: Jun 2008
Posts: 10
 

Lightbulb Re: Edit Fast Lane Checkout to show images instead of text

Well. I figured it out after some thinking. In the checkout_2_method.tpl file. I changed the line:
Code:
<td width="80%">{$payment.payment_details}</td>

to

Code:
<td width="80%"><img src="{$ImagesDir}/pm{$payment.paymentid}.png" align="right" alt="{$payment.payment_method}"/>{$payment.payment_details}</td>

Each payment method has a unique id, so I had to name the images using that id number (ex. pm1.png)
__________________
Version 4.1.9
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 01:59 AM.

   

 
X-Cart forums © 2001-2020