View Single Post
  #7  
Old 07-10-2007, 12:14 AM
 
ITVV ITVV is offline
 

X-Wizard
  
Join Date: Nov 2006
Location: UK
Posts: 1,164
 

Default Re: Payment methods - Special instructions - HTML - call .tpl coding help

Hi Guys,

Just to explain a little more about the mod I did to the Checkout page.

I did the mod as per Fearnothing's excellent suggestion at http://forum.x-cart.com/showthread.php?t=22197&page=4 article #37.

This mod allows you to use the "Special Instructions" box on the Payment meathods page in Admin to display .gif images of credit cards as per the following screen shot contained in the attachment xcart-payment-001.jpg.

Notice the Visa and MasterCard gif's along with the PayPal gif.

What I am trying to do is write some code for the "Cheque" payment method that takes the value of $ruby_store_currency and then displays information in that box based on the currency set, along the following lines: -

{if $ruby_store_currency eq GBP}
{include file="skin1/modules/Fast_Lane_Checkout/GBP_pay.tpl"}
{if $ruby_store_currency eq USD}
{include file="skin1/modules/Fast_Lane_Checkout/USD_pay.tpl"}
{/if}

In the above example if $ruby_store_currency = GBP it would include a file called GBP_pay.tpl with the following HTML code: -

Please make cheque payable to anycompany.com and send to: -

Anycompany.com
Any Street Road
Any Town
Any Country
Any Zip Code
UK

Cheques must be in Pound Sterling

In the next example if $ruby_store_currency = USD it would include a file called USD_pay.tpl with the following HTML code: -

Please make cheque payable to anycompany.com and send to: -

Anycompany.com
Any Street Road
Any Town
Any Country
Any Zip Code
United States

Cheques must be in United States Dollars

But when I click on "Checkout" as in the first step to complete your order and are taken to the Payment Method screen, the url shows: -

https://whatevercompany.com/cart.php?mode=checkout

All I am getting is the actual code that I have written in the Cheque (Admin - Payment Methods - Special instructiosn box) box, as contained in the attachment xcart-payment-002.jpg

Any thoughts on how I can achieve this please?

Many thanks in advance and kind regards to all

Nick
Attached Thumbnails
Click image for larger version

Name:	xcart-payment-001.jpg
Views:	221
Size:	36.5 KB
ID:	455  Click image for larger version

Name:	xcart-payment-002.jpg
Views:	216
Size:	23.7 KB
ID:	456  
__________________
X-Cart Pro 4.7.12 Active and working great with reBOOT-reDUX
X-Cart Pro 4.6.6 Retired after 6 years of first class service
X-Cart Pro 4.1.7 Retired after 9 years of first class service

Apache: 2.4.25
PHP: 7.4.5
MariaDB: 10.1.44
Arch: x86_64
Reply With Quote