Page 22 of 81 FirstFirst ... 1220212223243272 ... LastLast
Results 211 to 220 of 808
  1. #211
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Dynamic Filter [Support Thread]

    Ok so first things first.

    Do any of the files that have be overridden been modified by any of your other mods?

    Secondly, starting to come back to me now. Pretty sure almost all if not all of the header files were out of date? Check the file version compared to the dynamic filter ones, I think I had to merge them.

    Don't worry about cannonical, that doesn't do anything at this stage. All it will do is ensure that your canonical links in the source are correct when the filters are applied.
    Phil Rogers
    A problem shared is a problem solved.

  2. #212
    Join Date
    Dec 2012
    Posts
    607
    Plugin Contributions
    0

    Default Re: Dynamic Filter [Support Thread]

    Quote Originally Posted by philip937 View Post
    Ok so first things first.

    Do any of the files that have be overridden been modified by any of your other mods?
    I removed the only one that did, which was Products Listing Sorter v1.1

    Secondly, starting to come back to me now. Pretty sure almost all if not all of the header files were out of date? Check the file version compared to the dynamic filter ones, I think I had to merge them.
    Oh I have to look at that.

    Don't worry about cannonical, that doesn't do anything at this stage. All it will do is ensure that your canonical links in the source are correct when the filters are applied.

    ps. where can I get DrByte's Code revision?
    Using Zen Cart 1.5.1

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

    Default Re: Dynamic Filter [Support Thread]

    So you use the 1.5.1 file and change this function re written by DrByte
    http://www.zen-cart.com/showthread.p...44#post1188244

    That should be the only function in the file that is changed for dynamic filter and that version DrByte rewrote works fine for dynamic filter
    Phil Rogers
    A problem shared is a problem solved.

  4. #214
    Join Date
    Dec 2012
    Posts
    607
    Plugin Contributions
    0

    Default Re: Dynamic Filter [Support Thread]

    OK then in:
    (1) Code from the mod - Creating the error and the white page.
    PHP Code:
      function zen_get_all_get_params($exclude_array ''$search_engine_safe true) {

        if (!
    is_array($exclude_array)) $exclude_array = array();

        
    $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) > || 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
              
    }
            }
          }
        }
        while (
    strstr($get_url'&&')) $get_url str_replace('&&''&'$get_url);
        while (
    strstr($get_url'&&')) $get_url str_replace('&&''&'$get_url);

        return 
    $get_url;
      } 

    (2)DrBytes revision:
    PHP Code:
      function zen_get_all_get_params($exclude_array = 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 (!
    in_array($key$exclude_array)) {
              if (!
    is_array($value)) {
                if (
    is_string($value) && strlen($value) > 0) {
                  
    $get_url .= zen_sanitize_string($key) . '=' rawurlencode(stripslashes($value)) . '&';
                }
              } else {
                foreach(
    array_filter($value) as $arr){
                  
    $get_url .= zen_sanitize_string($key) . '[]=' rawurlencode(stripslashes($arr)) . '&';
                }
              }
            }
          }
        }
        while (
    strstr($get_url'&&')) $get_url str_replace('&&''&'$get_url);
        while (
    strstr($get_url'&&')) $get_url str_replace('&&''&'$get_url);

        return 
    $get_url;
      } 
    (3)Code from my backup working site before Dynamic Filter
    PHP 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)) . '&';
            }
          }
        }
        while (
    strstr($get_url'&&')) $get_url str_replace('&&''&'$get_url);
        while (
    strstr($get_url'&&')) $get_url str_replace('&&''&'$get_url);

        return 
    $get_url;
      } 
    I just have to replace (3) with (2)?
    Using Zen Cart 1.5.1

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

    Default Re: Dynamic Filter [Support Thread]

    Correct replace with (2) make sure you are doing this in a clean v1.5.1 functions general file

    however I'm pretty sure that is not what is causing your error as I did not face the same thing. All this code change did was stopped some error log warnings.

    I suspect that the problem is with other files that haven't merged properly.

    You need to check the override files vs the version revisions of the 1.5.1 files they override. If they are older then they need to be merged. Will be going to bed very soon so won't be able to reply for a while. Just take it step by step one file at a time. The key is to ensure you are using the same files as version 1.5.1 uses and merge the changes dynamic filter makes.

    On the plus side, I didn't find it hard to merge any of them apart from the functions general one to make it all good which DrByte kindly stepped in a did for us.
    Last edited by philip937; 23 Feb 2013 at 11:38 PM.
    Phil Rogers
    A problem shared is a problem solved.

  6. #216
    Join Date
    Dec 2012
    Posts
    607
    Plugin Contributions
    0

    Default Re: Sorting Manufacturers on Dynamic Filter Sidebox

    Phil You are the best. That did it.

    It now works. No more white page. It seems to be functioning properly also. with no other revisions. I will let you know if I see other problems.

    now I have to add the following to /includes/classes/shopping_cart.php line 1904-1906:
    PHP Code:
    //      zen_redirect(zen_href_link($_GET['main_page'], zen_get_all_get_params(array('action', 'notify', 'main_page'))));
    //      zen_redirect(zen_href_link(FILENAME_ACCOUNT_NOTIFICATIONS, zen_get_all_get_params(array('action', 'notify', 'main_page'))));
          
    zen_redirect(zen_href_link($_GET['main_page'], zen_get_all_get_params(array('action''notify''main_page')))); 
    as DrByte recommends. Doctor knows best.

    @DrByte, this revision should be it. Correct? And I should not have the following issue?
    Quote Originally Posted by DrByte View Post
    Ya, but now you may have problems with users creating accounts or resetting passwords etc.
    Thank you DrByte.
    Using Zen Cart 1.5.1

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

    Default Re: Sorting Manufacturers on Dynamic Filter Sidebox

    Glad to hear it. Yes I will be adding that code also when I get around to it. The Dr knows best as you say. Glad you got it sorted. Still worth treble checking that all your files are up to date.

    Take care :-)
    Phil Rogers
    A problem shared is a problem solved.

  8. #218
    Join Date
    Jan 2004
    Posts
    66,419
    Blog Entries
    7
    Plugin Contributions
    277

    Default Re: Sorting Manufacturers on Dynamic Filter Sidebox

    Correct.
    .

    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.

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

    Default Re: Sorting Manufacturers on Dynamic Filter Sidebox

    I do not see the top category, but I see it filtered by Brand and Price (This top category does not have any sub-categories.)
    PHP Code:
    index.php?main_page=index&cPath=
    I do not see the top category, or any other filter in (This has sub-categories.)
    PHP Code:
    index.php?main_page=index&cPath=
    .

    Is there any way to see all the categories including the top category filterable in the side box, in the filter area? As you see it in
    PHP Code:
    index.php?main_page=products_all 
    Last edited by Kevin205; 25 Feb 2013 at 06:11 AM.
    Using Zen Cart 1.5.1

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

    Default Re: Sorting Manufacturers on Dynamic Filter Sidebox

    There are only various views when you see the category filter.

    Products new and products all, probably search (though not got to testing that yet) and manufacturers pages.

    There would be no point having filter by category when you are already viewing a category. Similarly on manufacters pages category filter shows but manufacters filter does not.
    Phil Rogers
    A problem shared is a problem solved.

 

 
Page 22 of 81 FirstFirst ... 1220212223243272 ... LastLast

Similar Threads

  1. Hebrew Support - latest release [Support Thread]
    By eranariel in forum Addon Language Packs
    Replies: 20
    Last Post: 23 Apr 2025, 08:49 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

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR