I know, and I had a quick look at it making the count dynamic, some time ago. For now I do not have the time to fix this.
Printable View
Another suggestion for the future
While I have been able to incorporate currency symbols that fall on the right of the value by adding the following to tpl_dynamic_filter.php
I have not been able to add the 'thousands point', I have tried to extract the code needed from /classes/currencies.php without successCode:$currencies->currencies[$currency_type]['symbol_right']
Perhaps these two points could be included in the next version.Code:$rate = (zen_not_null($currency_value)) ? $currency_value : $this->currencies[$currency_type]['value'];
$format_string = $this->currencies[$currency_type]['symbol_left'] . number_format(zen_round($number * $rate, $this->currencies[$currency_type]['decimal_places']), $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];
Im trying to add this plugin to my 1.5.1 fresh install, no mods are added to it yet.
It gives me a blank page and in the /logs/ file i find this;
[10-Sep-2013 11:48:17 Europe/Amsterdam] PHP Fatal error: Cannot redeclare zen_create_random_value() (previously declared in /var/www/vhosts/mydomain.com/httpdocs/x/includes/functions/functions_general.php:626) in /var/www/vhosts/mydomain.com/httpdocs/x/includes/functions/password_funcs.php on line 86
Is there a fix available for this? Ive googled on this error and found some other people with the same problem but no solution :(
Can somebody point me in the right direction to fix this so i can use this awesome plugin ?
Managed to fix it with instructions found somewhere on the web, you have to grab the functions_general.php from the original 1.5.1 zencart, then mod that with this:
Find :
Replace with:Code:function zen_get_all_get_params($exclude_array = '', $search_engine_safe = true) {
if (!is_array($exclude_array)) $exclude_array = array();
$exclude_array = array_merge($exclude_array, array(zen_session_name(), 'main_page', 'error', 'x', 'y'));
$get_url = '';
if (is_array($_GET) && (sizeof($_GET) > 0)) {
reset($_GET);
while (list($key, $value) = each($_GET)) {
if (is_array($value) || in_array($key, $exclude_array)) continue;
if (strlen($value) > 0) {
$get_url .= zen_sanitize_string($key) . '=' . rawurlencode(stripslashes($value)) . '&';
}
}
}
Solution by : Design75Code:function zen_get_all_get_params($exclude_array = '', $search_engine_safe = true) {
if (!is_array($exclude_array)) $exclude_array = array();
$exclude_array = array_merge($exclude_array, array(zen_session_name(), 'main_page', 'error', 'x', 'y'));
$get_url = '';
if (is_array($_GET) && (sizeof($_GET) > 0)) {
reset($_GET);
while (list($key, $value) = each($_GET)) {
// bof dynamic filter 1 of 3
if ( (!in_array($key, $exclude_array)) && (strlen($value) > 0 || is_array($value) && array_filter($value) ) && ($key != 'main_page') && ($key != zen_session_name()) && ($key != 'error') && ($key != 'x') && ($key != 'y') ) {
// eof dynamic filter 1 of 3
if ( (SEARCH_ENGINE_FRIENDLY_URLS == 'true') && ($search_engine_safe == true) ) {
// die ('here');
$get_url .= $key . '/' . rawurlencode(stripslashes($value)) . '/';
} else {
// bof dynamic filter 2 of 3
if (is_array($value)) {
foreach($value as $arr){
$get_url .= zen_sanitize_string($key) . '[]=' . rawurlencode(stripslashes($arr)) . '&';
}
} else {
// eof dynamic filter 2 of 3
$get_url .= zen_sanitize_string($key) . '=' . rawurlencode(stripslashes($value)) . '&';
// bof dynamic filter 3 of 3
}
// eof dynamic filter 3 of 3
}
}
}
}
Manged to get it partially working,
Filtering works as intented on the products_all page, i can filter there for my attribute.
I have created an attribute that holds the value (vehicle the parts fits on)
On the products_all page it works great and shows me the right products with that attribute.
When i go to the category page, which shows me a list of all the products in that category, it does not work.
I Will try to explain with some screenshots..
Everything working correctly in the products_all screen:
http://i.imgur.com/gjftHm6.jpg
Failing in category screen:
http://i.imgur.com/ACEKF9P.jpg
Hopefully somebody can point me in the right direction to get this fully functional, im possibly doing something wrong :(
Attachment 13095Attachment 13096
It has been a long time since i have installed Dynamic Filter.
When you add a new attribute to a product, in this case a Read Only Attribute, named: Style. Would Style automatically appear in the filter set? Or you should modify a file somewhere?
Managed to get it working, somehow i screwed up uploading index_filters file, after reuploading that it now works like a charm :)
so if u run into problem, make sure you uploaded index_filters to the right location
/httpdocs/Shop/includes/index_filters/your_template/
Hi, great mod by the way. I just have one problem that i could use your help with if you dont mind.
I have dynamic filter installed on a v1.51 site, and i have just installed stock by attributes. Dynamic filter was working great before, but now the filter sidebox will only show attributes if they have stock assigned to them in the stock by attributes mod. As most my filters are read only and not meant to have stock levels this is a bit of a problem. Is there a work round this at all, or am i going to have to assign stock levels to all my read only attributes? Thanks in advance.