Page 121 of 227 FirstFirst ... 2171111119120121122123131171221 ... LastLast
Results 1,201 to 1,210 of 2267
  1. #1201
    Join Date
    May 2006
    Posts
    725
    Plugin Contributions
    0

    Default Re: Categories Dressing

    Quote Originally Posted by gjh42 View Post
    It needs some more specificity to overcome some other rule. Add #categories
    Code:
    #categories li.cat-top a:hover, #categories .catBoxHeading2 a:hover{background:#fff url(/includes/templates/custom/images/bc_cat_no_sub_hover.gif) no-repeat}
    Also, if you are deleting unused rules, what about .catBoxHeading3 and .catBoxHeadingImg?
    Thanks so much!!!
    We're still using .catBoxHeading3. Deleted .catBoxHeadingImg.

    Thanks again for this awesome mod!!!

  2. #1202
    Join Date
    Dec 2009
    Location
    Sarajevo
    Posts
    80
    Plugin Contributions
    0

    Default Re: Categories Dressing

    Quote Originally Posted by gjh42 View Post
    adi2009 - My last post to you was specific about the location of categories and chcategories. It won't work correctly with them the other way. And you won't need to have two different settings, once a small change is made to a function in categories_dressing_functions.php. Essentially we need to make the code treat first level subcats as if they were top level cats. I will look at that soon and post the change required.

    The stylesheet code will be something like
    #chcategories ul ul ul {/*hide all deeper than first subcategory lists - left box*/
    display: none;
    }

    #categoriesContent>ul>li>ul>li>a {/*hide only first level subcategories - right box*/
    display: none;
    }


    In /includes/functions/extra_functions/categories_dressing_functions.php, find this
    PHP Code:
        }//switch
        
    if ($test_level){
          switch (
    'true'){
            case (
    $cat_box_active_level[1] > $cat_depth): 
    and add this just before it
    PHP Code:
          case 7://full active subtree, others per level - treat first subcat like top - customized 20100205 for madijelovi
            
    if($cPath_top != $path_top){//only 1 top cat's subs
              
    $skip_cat 1;
              break;
            }
            
    $cPath_top_special = (int)substr_replace($_GET['cPath'],'',0,strpos($_GET['cPath'],'_')+1) ;//remove before & incl 1st occurrence of _ in string
            
    $path_top_special = (int)substr_replace($path,'',0,strpos($path,'_')+1) ;//remove before & incl 1st occurrence of _ in string
            
    if($cPath_top_special != $path_top_special$test_level 1;
            break; 
    to get this
    PHP Code:
          case 7://full active subtree, others per level - treat first subcat like top - customized 20100205 for madijelovi
            
    if($cPath_top != $path_top){//only 1 top cat's subs
              
    $skip_cat 1;
              break;
            }
            
    $cPath_top_special = (int)substr_replace($_GET['cPath'],'',0,strpos($_GET['cPath'],'_')+1) ;//remove before & incl 1st occurrence of _ in string
            
    $path_top_special = (int)substr_replace($path,'',0,strpos($path,'_')+1) ;//remove before & incl 1st occurrence of _ in string
            
    if($cPath_top_special != $path_top_special$test_level 1;
            break;
        }
    //switch
        
    if ($test_level){
          switch (
    'true'){
            case (
    $cat_box_active_level[1] > $cat_depth): 
    I haven't tested this, and you may need something slightly different, but it will be similar. Let me know what happens.

    You will want a define setting of '7|4|5' ; change the 4 and 5 if needed, but you must use the 7.

    thank you Glenn for detail explanation regarding my last post, truly appreciate it. Following your instructions from your last post, this is what I done:

    1. First,I set chcategories sidebox in the left and classic categories in right column

    2. This part of code I have insert in "stylesheet_categories_dressing.bak.css"

    Code:
    #chcategories ul ul ul {/*hide all deeper than first subcategory lists - left box*/
        display: none;
        }
    and this part of code I have insert in "stylesheet_categories_dressing.css"

    Code:
    #categoriesContent>ul>li>ul>li>a  {/*hide only first level subcategories - right box*/
        display: none;
        }
    3. I have added /case 7/ successfully in "categories_dressing_functions.php" and used define setting of '7|4|5'

    Result of all changes is that I know have someting that is close to soultion I need need, so it look like we are on right track Here's how it looks like now after changes:

    - Left chcategories is now showing only top and first level subcategories but what is intresting that is only showing one record (categor./subcat.) and never more that one even with fact there are for example five 1stlevel subcategories, its always showing one (currently selected).

    - Right categories sidebox is now not showing 1st level subcategorie (in my case 1stlev.subcat. is Car Brand) and thats OK but it shows all 2nd level subcat. (Car Model), 3th level subcat. (Engine/year/hp) and 4thlevel subcat. (Spare part types).
    I planned for this right sidebox to show only 4thlevel subcat. so I need some change in code to show only 4th level subcat.
    Than I could achieve same system as on Example link I mention earlyer, for example:

    1. enduser chooses Car brand (1st l.s.) on the left sidebox chcategories,
    2. than Car model (2nd l.s.) in center page
    3. than he chooses Engine/year/hp (3th l.s.) also in center page
    4. then Spare part type (4 l.s. for example 'Brakes')
    5. and than at the end when he is viewing product listing - spare part list he is interested in, on right side (in right column) classic categories sidebox should appear, which would show only 4th level subcat. ("Engine parts", "Brakes", "Suspenison" etc) for 'CarBrand'--->'Model'--->'Engine/year/hp' he choosed.
    Last edited by adi2009; 6 Feb 2010 at 11:05 AM.

  3. #1203
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Categories Dressing

    Knowing the exact subcat levels to display helps. Will there ever be deeper levels of subcat?
    I don't know why it is only showing one first subcat, so I have improved a few things and put a debug line in the function. Install this in place of the original case 7
    PHP Code:
          case 7:// active subtree, active branches only, only 1st & 4th level - treat first subcat like top - customized 20100205 for madijelovi
            
    if($cPath_top != $path_top){//only 1 top cat's subs
              
    $skip_cat 1;
              break;
            }
            if(
    $cat_depth == 1){//show all first level  subs
    echo '<br />first: '.$path;//debug
              
    break;
            }
            if(
    $cat_depth == 4){//check 4th level for active parent
              
    $path_ids explode('_',$path);
              
    $path_parent $path_ids[count($path_ids)-2];
              if (
    in_array($path_parent,explode('_',$_GET['cPath']))) break;//show only subcats w parent in $cPath
            
    }
            
    $skip_cat 1;//skip all others
            
    break; 
    It should output some numbers in the category boxes like first: 147_199. Let me know when you have applied this, and I will look at it to see what it does.

  4. #1204
    Join Date
    Dec 2009
    Location
    Sarajevo
    Posts
    80
    Plugin Contributions
    0

    Default Re: Categories Dressing

    Amazing Glenn you are real Zen Guru It exactly what my client had in mind and its working great.

    Also, as you mentioned in your post, it outputed numbers like 'first: 147_199' I notice that part of code and uncomment it, so code now looks like this:

    Code:
    case 7:// active subtree, active branches only, only 1st & 4th level - treat first subcat like top - customized 20100205 for madijelovi
            if($cPath_top != $path_top){//only 1 top cat's subs
              $skip_cat = 1;
              break;
            }
            if($cat_depth == 1){//show all first level  subs
    //echo '<br />first: '.$path;//debug
              break;
            }
            if($cat_depth == 4){//check 4th level for active parent
              $path_ids = explode('_',$path);
              $path_parent = $path_ids[count($path_ids)-2];
              if (in_array($path_parent,explode('_',$_GET['cPath']))) break;//show only subcats w parent in $cPath
            }
            $skip_cat = 1;//skip all others
            break;
    and now its not shows paths, is this OK?

    p.s. I just noticed that categories.php in right column is also showing when I am on 4th level subcategorie: when I am viewing Car Parts Types for example 'Brakes'; 'Engine Parts' 'Suspension' etc in main/center page, I am also seeing classic categories on right side (in right column) which is showing same list - Car Parts Types. I am not sure what part of code we should change so the categories on right side wouldnt be visible when users are viewing Car Parts Types..

    Thank you!
    Last edited by adi2009; 6 Feb 2010 at 08:56 PM.

  5. #1205
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Categories Dressing

    If you want the right sidebox to not show when the same set of subcats is displayed in the center, that can be done. I won't have much time to work on it for the rest of the weekend - will come back when I can.

  6. #1206
    Join Date
    Dec 2009
    Location
    Sarajevo
    Posts
    80
    Plugin Contributions
    0

    Default Re: Categories Dressing

    OK Glenn

  7. #1207
    Join Date
    Jan 2010
    Posts
    8
    Plugin Contributions
    0

    Default Re: Categories Dressing

    Hi, I am very new to all this, a bit lost, and in need of kind help!

    After installing the module only the first category has expanded to show the sub categories - I would like all the sub categories to show under each top category - how would I do this?

    The instructions in v2.7.3 readme seem to imply the answer to this maybe in 'readme_ch_categories.txt' but I can't work out where this file resides?

    Any help appreciated - Many thanks

  8. #1208
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Categories Dressing

    You do need the chcategories version for this.
    Both readme files should be in the base of the mod fileset when you unzip it. You will need to edit filepaths for /your_template/ in the chcategories folder, then upload that /includes/ folder like the other one. Select the chcategories sidebox in Tools > Layout Boxes Controller.

  9. #1209
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Categories Dressing

    zubenubi - You have put the rules for ul#catGroup6_8 { and ul#catGroup7_12 { near the top of your stylesheet, where some of their settings are being overruled by later generic settings. They need to go down in the same section as the others:
    Code:
    /*example for custom category group styling*/
    ul#catGroup3 {
    If this still does not work, you may need more specificity. Add #categories in front of the ul, like this:

    #categories ul#catGroup6_8 {

  10. #1210
    Join Date
    Jan 2010
    Posts
    8
    Plugin Contributions
    0

    Default Re: Categories Dressing

    Thanks Glenn you are a star! and such a quick response!

    For some reason the readme files are not downloading - but your tip to activate the side box in the layout boxes controller has got the structure I wanted. I guess all I need to do now is just use the stylesheet_chcategories_dressing.css to customise the colours etc?

    Many thanks

 

 

Similar Threads

  1. categories dressing
    By fw541c in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 19 Nov 2010, 09:29 PM
  2. Categories Dressing
    By wotnow in forum Addon Sideboxes
    Replies: 10
    Last Post: 7 Apr 2010, 03:06 AM
  3. Categories Dressing issue
    By Maynards in forum Addon Sideboxes
    Replies: 0
    Last Post: 13 Mar 2010, 10:51 PM
  4. Categories Dressing
    By Maynards in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 12 Mar 2010, 11:05 PM
  5. Categories Dressing
    By PGlad in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 7 Aug 2007, 07:05 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