Hi,
I don't know if it's officially marked as compatible but it works fine on my site after upgrading to 1.5.1
I hope this helps.
Hi,
I don't know if it's officially marked as compatible but it works fine on my site after upgrading to 1.5.1
I hope this helps.
George
Athens Collectibles
Thank you.
I installed this and I have one flag image (when clicked oni t does nothing) and the currency symbols are working as links. I would like to use the images of flags as links. I download the flag gifs by bunyip and then when I look at my zencart it has 5 flags and the currency symbols side by side. Should I keep the flag gifs as one image? or do I need to separate them? and how to make flags as links? what do I need to edit?
I have copied all files to correctly folders and successfully applied the sql instructions.
In admin>config>layout settings I can see the 2 new additions and they are set to true. I am running this on my local machine using xampp.
Any help would be appreciated.![]()
I found the solution for adding flags as links instead of the currency symbol in another post THANKS TO RBARBOUR.
At present I have got it to display the flags and the links are working but its still displaying currency symbols also. I am still working on it.
However if you want to achieve this, look at the suggestion in the link below.
http://www.zen-cart.com/showthread.p...ge+link+header
Basically go to your tpl_header_currencies and give the link an ID:
$content = " ";
for ($i=0; $i<sizeof($currencies_array); $i++) {
$content .= '<a id="navTopCurrencyId' . $currencies_array[$i]['id'] . '"' . 'href="' . zen_href_link($_GET['main_page'], zen_get_all_get_params(array('language')) . 'currency=' . $currencies_array[$i]['id'], $request_type) . '">' . $currencies_array[$i]['text'] . '</a> ';
}
echo $content;
?>
and then add in your css style sheet this css.
#navTopCurrencyIdUSD {
padding:0px 2px 7px 30px;
background-image: url(../images/USD.png);
background-repeat:no-repeat;
}
and repeat it for each flag.
Finally, I've updated Language/Currency Links in Header for Zen Cart 1.55f including Mobile/Responsive Template files!
It should be available shortly in the forum and as always on my site.
How it works:
- You can now display the language icons (flags) and currency symbols as links in the navigation section of your header.
- Switch displays in the line below the Home/Log In/Shopping Cart header and by default floats to the right WITH the search header ON/OFF (desktop).
- Loads below main logo on all mobile pages to prevent conflict with stock menu flyout (mobile).
- In Admin > Configuration > Layout Settings - Turn Languages/Currencies ON/OFF
Key Features
- Installs into Template Default, Responsive_Classic and YOUR_TEMPLATE
- Design notes included for easy updates - CSS styling
- Compatible with text-icon swap for currency display
- Code is split to display on mobile/responsive or desktop with separate CSS
Install Into:
- Admin, Live Site
Works With:
- All Twitch Modules
Note: This module is compatible with post #64:
https://www.zen-cart.com/showthread....34#post1214534
If my work has helped you today in any way, show your appreciation with things like positive feedback or donations.
Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
Twitch Base8 - Obsidian - This, is what's new.
For those wanting to add the currency 'code' or currency ID to the desktop header display...
Stock Display:
Language [Flag] $ € £ $ $
Add ID to Display:
Language [Flag] USD $ EUR € GBP £ CAD $ AUD $
includes/templates/YOUR_TEMPLATE/common/tpl_header_currencies.php
replace line 13
$content .= '<a href="' . zen_href_link($_GET['main_page'], zen_get_all_get_params(array('language')) . 'currency=' . $currencies_array[$i]['id'], $request_type) . '">' . $currencies_array[$i]['text'] . '</a> ';
with this:
$content .= '<a href="' . zen_href_link($_GET['main_page'], zen_get_all_get_params(array('language')) . 'currency=' . $currencies_array[$i]['id'], $request_type) . '">' . $currencies_array[$i]['id'] . ' ' . $currencies_array[$i]['text'] . '</a> ';
Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
Twitch Base8 - Obsidian - This, is what's new.
Reminder in case this answer got lost...
The code is designed to be hidden during checkout by default to ensure the language and currency is maintained during the checkout before passing data to API's and the like...
includes/modules/YOUR_TEMPLATE/header_currencies.php
PHP Code:
// test if box should display
$show_currencies= false;
// don't display on checkout page:
if (substr($current_page, 0, 8) != 'checkout') {
$show_currencies= true;
}
Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
Twitch Base8 - Obsidian - This, is what's new.
There now exists an add-on upgrade pack for this module:
Twitch Add Sort Order Control to Language/Currency Links in Header
This module will install sort_order into your already installed 'Language/Currency Links in Header' module and allow use of the new sort field in Admin > Localization > Currencies
The default function of the stock header_currencies is to simply print out each value found in the currency array one at a time matched to the order found in the DB [currency ID]. This doesn't allow control of display unless the ID hard code is changed. So I added a sort_order column to ensure anything using the code, title or currency ID will NOT be affected sitewide. I have also limited the data manipulation using sort to the final - currency header display only.Because this module installs using NULL in the sort_order:
- Admin will display alphabetically by currency name until there are sort orders to sort through
- If the code can not resolve a sort conflict it will get screwy and follow the next logical output possible - likely title.
As an added feature:
The admin display sort order is ALSO the sort order used on the live site.
- That means you will see immediately the order the site will display in admin each time you update the sort order.
- This will help prevent duplicate sort order # problems also :)
This add on module is available on my site and I am in the process of merging it with the recent Language/Currency Links in Header v2.0 for v2.1 release shortly!
Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
Twitch Base8 - Obsidian - This, is what's new.
ZC Version 1.5.6a and I have very little modifications made to the stock files...
I got this to work on my site. Managed to have the currency ID show by changing in Localisation de Symbol to the Symbol and ID which in my case, helps. Now it shows as I want it on desktop and mobile but can't make it show on tablet. Am I doing something of when specified mobile below it is because it is mobile only? And if that is the case, can you offer some pointers on having it show on tablet?
thanks you
I found this code that calls to both mobile and tablet... and it works on mobile but it doesn't detect it on my tablet
<?php if ( $detect->isMobile() && !$detect->isTablet() || $_SESSION['layoutType'] == 'mobile' ) { ?>
<!-- <div id="navMainSearch1" class="forward"><?php // require(DIR_WS_MODULES . 'sideboxes/search_header.php'); ?></div> -
Bookmarks