Zen cart installation / maintenance / customisation / hosting
Supported Modules: Dutch language pack, Multi site, Dynamic Price Updater and more.
I don't think you can.
Using Zen Cart 1.5.1
Zen cart installation / maintenance / customisation / hosting
Supported Modules: Dutch language pack, Multi site, Dynamic Price Updater and more.
Hi ,
I've just noticed after introducing manufacturers the following error for dynamic filter:
[05-Apr-2013 20:37:49 UTC] PHP Fatal error: 1064:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '), 'Y', 'N') as flag FROM manufacturers WHERE manufacturers_id IN (1,2) ORDER BY' at line 1 :: SELECT manufacturers_id, manufacturers_name, IF(manufacturers_id IN(), 'Y', 'N') as flag FROM manufacturers WHERE manufacturers_id IN (1,2) ORDER BY manufacturers_name in C:\xampp\htdocs\zencart\includes\classes\db\mysql\query_factory.php on line 120
Anyone knows how to fix it?
The code is here:
$manufacturers = $db->Execute("SELECT manufacturers_id, manufacturers_name, IF(manufacturers_id IN(" . implode(',', $filteredManufacturers) . "), 'Y', 'N') as flag" .
" FROM " . TABLE_MANUFACTURERS .
" WHERE manufacturers_id IN (" . implode(',', $unfilteredManufacturers) . ")" .
" ORDER BY manufacturers_name");
My appologizes for my maybe incorrect English, i hope you will understand me.
I have a problem with the dynamic filter. As i understand, you made this filter.
The search by price option, are prices excluding VAT/TAX.
So with a search from 10 till 20, products above 20 (we have 21% tax). So a product with a price of 24 will be shown in the list 10 till 20.
We have been scripting a while now, but can't figure out how we can get to filter for prices including tax.
Is there a way to solve this problem?
I think I solved the tax problem
In includes/templates/YOUR_TEMPLATE/sideboxes/tpl_dynamic_filter.php find
and replace withPHP Code:if ($end < $max) $text = $currency_symbol . round($start * $conversion_rate) . ' -- ' . $currency_symbol . round($end * $conversion_rate);
else $text = $currency_symbol . round($start * $conversion_rate) . ' and over';
It works for me, but some further testing is needed, before releasing an update for this modulePHP Code:if ($end < $max)
{
$text = $currency_symbol . round((zen_add_tax($start, $products_tax)) * $conversion_rate) . ' -- ' . $currency_symbol . round((zen_add_tax($end, $products_tax)) * $conversion_rate);
}
else
{
$text = $currency_symbol . round((zen_add_tax($start, $products_tax)) * $conversion_rate) . ' and over';
}
If this works, the next step is to replace the hard-coded text for language defines, to make this mod multilingual
Zen cart installation / maintenance / customisation / hosting
Supported Modules: Dutch language pack, Multi site, Dynamic Price Updater and more.