Results 1 to 3 of 3
  1. #1
    Join Date
    Apr 2007
    Location
    Sydney
    Posts
    109
    Plugin Contributions
    0

    Default What is the variable that represents the selected currency?

    I'm trying to display postage in customer's selected currency, in one of the define pages.

    It's $15 Australian dollars flat rate, so if an European selects Euros in the currency side box, the postage should automatically change to 7.3 Euros.

    Now I've worked out the code below would do the conversion, but it only shows the dollar number i.e. 7.3. How can I display the actual currency (€ or Euro)?
    Code:
    <?php $amount=15; echo $currencies->value($amount);?>

  2. #2
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: What is the variable that represents the selected currency?

    try $currencies->format() instead of ->value()
    .
    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Apr 2007
    Location
    Sydney
    Posts
    109
    Plugin Contributions
    0

    Default Re: What is the variable that represents the selected currency?

    Works beautifully!! Thank you DrByte!

 

 

Similar Threads

  1. what is the variable for the contact_us page?
    By nwms8 in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 21 Jul 2010, 07:55 AM
  2. Hiding a second currency when the second currency is selected as primary.
    By gamestuff in forum Currencies & Sales Taxes, VAT, GST, etc.
    Replies: 0
    Last Post: 30 Nov 2009, 09:01 PM
  3. What is the variable for specials
    By kands in forum General Questions
    Replies: 2
    Last Post: 11 May 2007, 08:38 PM
  4. What is the variable for the template directory?
    By paul3648 in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 7 Apr 2007, 06:37 AM
  5. Payment module based on currency that is selected
    By focus360 in forum Currencies & Sales Taxes, VAT, GST, etc.
    Replies: 1
    Last Post: 16 Nov 2006, 06:57 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg