Page 1 of 2 12 LastLast
Results 1 to 10 of 809

Hybrid View

  1. #1
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Help with Dynamic filter 1.1

    I have installed this onto 1.5.1 and love it, works perfect! Only problem is the expand and collapse box feature isn't working at all, all settings are being ignored and is always fully expanded?

    Anyone else had the same problem? Anyone able to suggest how to fault find it?

    I have been through the docs and checked all the installations files are present and correct.

    Thanks

    Phil
    Phil Rogers
    A problem shared is a problem solved.

  2. #2
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    really could do with some help here, ive checked the html markup to see if there are any template clashes but all looks ok to me.

    whats weird is that the link for the expanding etc is in the code but not showing on the page:

    <a class="dFilterToggle" href="#">More<img src="includes/templates/mytemplate/images/arrow_more.gif" alt="More" title=" More " width="10" height="10" class="dFilterToggleImg" /></a>

    as a test I just took this code and pasted into an EZ page.. guess what still nothing showed on the page?

    I have noticed there are two class elements class="dFilterToggle" & class="dFilterToggleImg"

    is this normal? so at the moment I am unsure if it is the code above causing the problem, of the js not making the link appear??
    Phil Rogers
    A problem shared is a problem solved.

  3. #3
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    Fixed. All very weird, bit of a clash with something else I use that needs jquery but seems one needs to load before CSS and one after.. Also both seem to need different flavours of jquery? Which I'm confused about, I thought putting the most up to date would cover both??
    Phil Rogers
    A problem shared is a problem solved.

  4. #4
    Join Date
    Jan 2006
    Posts
    420
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    Hello "fancie" Phil
    Glad you got it sorted - I too am using this addon but could not find an official support thread for it !

    Have you worked out how to remove price ?
    price isn't something i need my customers to search on - just all the attributes that I am adding to the products as a read only.

    2nd on my wish list is to pull this from being a sidebox to include in the main page ( category page ) so it would dynamically change for each different category but in the main page rather than on a sidebox.

    Other than that loving it - keep it up Phil !
    Various Zen cart sites !

  5. #5
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    Quote Originally Posted by crazycucumber View Post
    Hello "fancie" Phil
    Glad you got it sorted - I too am using this addon but could not find an official support thread for it !

    Have you worked out how to remove price ?
    price isn't something i need my customers to search on - just all the attributes that I am adding to the products as a read only.

    2nd on my wish list is to pull this from being a sidebox to include in the main page ( category page ) so it would dynamically change for each different category but in the main page rather than on a sidebox.

    Other than that loving it - keep it up Phil !

    Hello crazycucumber!

    Pretty sure you can just remove the price code from the template though I havent tried it.. no sure if it need 'blank' entries when a query is submitted on the form or if it will just be as if none were selected.

    as for having different things on different categories, I would suggest you use the normal functionality of sideboxes and use IF statements based on the currenty category id and wrap it around your various boxes.. same aplies for this though I guess, if it needs all to be visible it wont work.

    so in

    includes/templates/your_template/sideboxes/tpl_dynamic_filter.php

    try commenting out this code:

    PHP Code:
    /********************************************start price range link/check boxes***************************************************/
        
    if (count($priceArray) > 0) {
            
    $priceGap floor(($max $min) / (FILTER_MAX_RANGES 1)); 
            if (
    FILTER_MIN_PRICE && $priceGap FILTER_MIN_PRICE$priceGap FILTER_MIN_PRICE;
            if (
    FILTER_MAX_PRICE && $priceGap FILTER_MAX_PRICE$priceGap FILTER_MAX_PRICE;
            
            
    $group DYNAMIC_FILTER_PREFIX str_replace(' '''DYNAMIC_FILTER_PRICE_GROUP);
            
    $resetParms[] = $group;
            
    $parameters zen_get_all_get_params();
            
    $dropdownDefault str_replace('%n'DYNAMIC_FILTER_PRICE_GROUPDYNAMIC_FILTER_DROPDOWN_DEFAULT);
            
    $priceCount 0;
            
    $prices '';
            
            for (
    $start $min 0.5$start $max$start $end 0.01) {
                
    $end round($start $priceGap);
                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';
                foreach(
    $priceArray as $price ){
                    if (
    $start <= $price && $end >= $price) {
                        if (isset(
    $_GET[$group]) && in_array($start '--' $end,$_GET[$group])) $linkClass 'selected';
                        else 
    $linkClass 'enabled';
                        break;
                    } else 
    $linkClass 'disabled';
                }
                
                
    $onClick '';
                if (
    FILTER_GOOGLE_TRACKING != 'No'$onClick .= $trackingStart '\'filterAction\', \'' . ($linkClass != 'selected' 'addFilter' 'removeFilter') . '\', \'' $pageName ';' DYNAMIC_FILTER_PRICE_GROUP '=' $start '-' $end '\'' $trackingEnd;
                if (
    FILTER_STYLE == 'Checkbox - Single'$onClick .= ' this.form.submit();';

                if (
    FILTER_METHOD != 'Hidden' || $linkClass != 'disabled') {
                    
    $hrefLink $group '[]=' $start '--' $end;
                    switch(
    strtok(FILTER_STYLE" ")) {
                    case 
    'Checkbox':
                        
    $prices .= '<li class="dFilterLink">' zen_draw_checkbox_field($group '[]'$start '--' $end, (isset($_GET[$group]) && in_array($start '--' $end,$_GET[$group]) ? true false), ($linkClass == 'disabled' 'disabled="disabled"' '') . ($onClick != '' && FILTER_STYLE == 'Checkbox - Single' ' onclick="' $onClick '"' '')) . $text '</li>';
                        break;
                    case 
    'Link':
                        
    $prices .= '<li class="dFilterLink"><a class="' $linkClass '"' . ($linkClass != 'disabled' ' rel="nofollow" href="' zen_href_link($_GET['main_page'], ($linkClass != 'selected' $parameters $hrefLink str_replace(array($hrefLink,'&'.$hrefLink), array("",""), $parameters)), 'NONSSL') . '"' . ($onClick != '' ' onclick="' $onClick '"' '') : '') . ' >' $text '</a></li>';
                        break;
                    case 
    'Dropdown':
                        
    $prices .= '<option value="' $start '--' $end '"' . ($linkClass == 'selected' ' selected="selected"' '') . ($linkClass == 'disabled' ' disabled="disabled"' '') . ($onClick != '' && FILTER_STYLE == 'Dropdown - Single' ' onclick="' $onClick '"' '') . ' >' $text '</option>';
                        break;
                    }
                }
                ++
    $priceCount;
            }
            
            
    $content .= '<hr width="90%" size="0" />';
            
    $content .= '<div><div class="dFilter"><p class="dFilterHeading">' DYNAMIC_FILTER_TEXT_PREFIX DYNAMIC_FILTER_TEXT_PRICE DYNAMIC_FILTER_TEXT_SUFFIX '</p>';
            if (isset(
    $_GET[$group]) && array_filter($_GET[$group])) $content .= '<div class="dFilterClear"><a href="' zen_href_link($_GET['main_page'], zen_get_all_get_params(array($group)), 'NONSSL') . '">' zen_image(DIR_WS_TEMPLATE_IMAGES 'clear_filter.png'DYNAMIC_FILTER_BUTTON_CLEAR_FILTER_ALT) . '</a></div>';
            if (
    strtok(FILTER_STYLE" ") == 'Dropdown'$content .= '<select name="' $group '[]" class="dFilterDrop"' . (FILTER_STYLE == 'Dropdown - Single' ' onchange="this.form.submit();"' '') . '>' '<option value=""' . (!isset($_GET[$group]) || !array_filter($_GET[$group]) ? ' selected="selected"' '') . '>' $dropdownDefault '</option>';
            else 
    $content .= '<ul' . ($priceCount FILTER_MAX_OPTIONS ? (FILTER_OPTIONS_STYLE == 'Scroll' ' class="dFilterScroll">' ' class="dFilterExpand">') : '>');
            
    $content .= $prices;
            if (
    strtok(FILTER_STYLE" ") == 'Dropdown'$content .= '</select>';
            else 
    $content .= '</ul>';
            if (
    FILTER_OPTIONS_STYLE == 'Expand' && $priceCount FILTER_MAX_OPTIONS$content .= '<a class="dFilterToggle" href="#">More' zen_image(DIR_WS_TEMPLATE_IMAGES 'arrow_more.gif''More''''''class="dFilterToggleImg"') . '</a>';
            
    $content .= '</div></div>';
        }
            
    /********************************************end price range link/check boxes***************************************************/ 
    not tried and tested, so back up beofre you try..
    Phil Rogers
    A problem shared is a problem solved.

  6. #6
    Join Date
    Jan 2006
    Posts
    420
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    Nope that broke the whole addon -

    I just changed the first line to

    Code:
        if (count($priceArray) < 0) {
    so it is never true ! Seems to work.
    Various Zen cart sites !

  7. #7
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    Quote Originally Posted by crazycucumber View Post
    Nope that broke the whole addon -

    I just changed the first line to

    Code:
        if (count($priceArray) < 0) {
    so it is never true ! Seems to work.
    that'll do it ;)
    Phil Rogers
    A problem shared is a problem solved.

  8. #8
    Join Date
    Dec 2009
    Location
    Amersfoort, The Netherlands
    Posts
    2,845
    Plugin Contributions
    25

    Default Re: Help with Dynamic filter 1.1

    Quote Originally Posted by philip937 View Post
    Fixed. All very weird, bit of a clash with something else I use that needs jquery but seems one needs to load before CSS and one after.. Also both seem to need different flavours of jquery? Which I'm confused about, I thought putting the most up to date would cover both??
    Hi philip,

    I know you reported this a while back, but since i am updatig this module, I thought to give you an update on this.

    The more/less button works fine when using jquery 1.4.4, but with higher versions it stops. Now we need to find out why :)

    The other updates to be included for now are all the code bugfixes / improvements reported in this thread since version 1.1 was released.

  9. #9
    Join Date
    Dec 2012
    Posts
    607
    Plugin Contributions
    0

    Default Re: Help with Dynamic filter 1.1

    Has anyone encountered similar errors with Dynamic Filter v1.0, when using ' for feet and " for inches and filtering for attribute size?
    Example Attribute Size: with value 1'-4" x 2'-6"

    [25-May-2013 18:09:05 America/Denver] 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 '71"", GROUP_CONCAT(CONCAT(REPLACE(po.products_options_name, " ", ""), pov.produc' at line 7 :: SELECT DISTINCT p.products_id, p.products_type, p.master_categories_id,
    p.manufacturers_id, p.products_price, p.products_tax_class_id, pd.products_description, IF(s.status = 1,
    s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status =1, s.specials_new_products_price,
    p.products_price) as final_price, p.products_sort_order, p.product_is_call, p.product_is_always_free_shipping,
    p.products_qty_box_status FROM zen_products p LEFT JOIN zen_specials s on p.products_id = s.products_id LEFT JOIN zen_products_description pd on p.products_id = pd.products_id JOIN zen_products_to_categories p2c on p.products_id = p2c.products_id JOIN zen_products_attributes p2a on p.products_id = p2a.products_id JOIN zen_products_options po on p2a.options_id = po.products_options_id JOIN zen_products_options_values pov on p2a.options_values_id = pov.products_options_values_id WHERE p.products_status = 1
    and pd.language_id = '1'
    and p2c.categories_id = '17' GROUP BY p.products_id HAVING ( FIND_IN_SET("Size:51" x 71"", GROUP_CONCAT(CONCAT(REPLACE(po.products_options_name, " ", ""), pov.products_options_values_name)))) in /MyPath/includes/classes/db/mysql/query_factory.php on line 120
    Using Zen Cart 1.5.1

  10. #10
    Join Date
    Dec 2009
    Location
    Amersfoort, The Netherlands
    Posts
    2,845
    Plugin Contributions
    25

    Default Re: Help with Dynamic filter 1.1

    Quote Originally Posted by Kevin205 View Post
    Has anyone encountered similar errors with Dynamic Filter v1.0, when using ' for feet and " for inches and filtering for attribute size?
    Example Attribute Size: with value 1'-4" x 2'-6"
    I entered a the value in a testshop and getting the same error. Like explained to you in other threads it has to do with the ' and " in the value name. I think the only solution right now is to use inch and ft instead

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Hebrew Support - latest release [Support Thread]
    By eranariel in forum Addon Language Packs
    Replies: 22
    Last Post: 26 Jan 2026, 06:47 AM
  2. Empty Dynamic Filter
    By LadyoftheCave in forum All Other Contributions/Addons
    Replies: 3
    Last Post: 6 Jun 2016, 12:47 PM
  3. v150 Dynamic filter
    By Dinoleix in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 13 Aug 2013, 10:23 AM
  4. v150 Dynamic filter - All pages
    By Okkwebmedia in forum Addon Sideboxes
    Replies: 0
    Last Post: 8 Jul 2013, 08:52 AM
  5. v138a Dynamic Filter
    By SoftCorpse in forum All Other Contributions/Addons
    Replies: 9
    Last Post: 18 Jun 2012, 01:32 PM

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