Results 1 to 10 of 12

Hybrid View

  1. #1
    Join Date
    Aug 2009
    Posts
    9
    Plugin Contributions
    0

    Default Re: Male/Female category sideboxes

    Ah ok. Thanks for the link. I have installed it and have found the thread on it. I'll be taking a look at it later.

    On first glance it seems I can create a new group (say for female) with CAT_BOX_HEADING_1, but won't I still up up against the same problem in that I'll need to know the variables to determine which links to list under which gender?

  2. #2
    Join Date
    Apr 2008
    Location
    Athlone, Ireland
    Posts
    176
    Plugin Contributions
    5

    Default Re: Male/Female category sideboxes

    Not at all.

    The way I did it is I put evey category as a top category, no subcats.

    I simply used images to create headers to make it look like I had to seperate lots of cats. Which makes all the Top categories under the headers look like sub cats.

    It takes a little time to get familiar with how it works,

    What you could do is, for womens cats create WCATSNAME and for men create MCATNAME as the category names.

    If you need any help with it let just reply in this tread or PM me and I will do my best to help you out. Or at least help to take some of the confussion away. lol

  3. #3
    Join Date
    Aug 2009
    Posts
    9
    Plugin Contributions
    0

    Default Re: Male/Female category sideboxes

    But I want to keep the heirarchy of the categories as it fits with the way we are presenting our products. But in addition to that I want a different heirarchy for the sidebox. I thik that may be where my confusion comes into it.

    It may help if I showed the site (still in progress):
    http://shop.mayamada.com

    If you click at the images you'll see the category structure (we don't sell shoes by the way, just haven't switched the images yet) which I want to keep the same:

    Category->[Male/Female]->[Male/female] products

    But I want a different structure for the categories sidebox i.e. [Male/Female] Category list->[Male/Female] product list for that category.

    Is it possible to do this with Categories Dressing as it still seems to me that I'll have to make use of the variables?

    I still may be missing something though.

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

    Default Re: Male/Female category sideboxes

    You need to know which categories are for male or female products, and give them sort orders in Catalog > Categories/Products > edit category page > sort order box at bottom left. (Say all "male" cats are sort order 1000-1990 and all "female" cats are 2000-2990.) They will then fall into place in the categories sidebox, and you can use the first one of each set to mark the group.
    If you don't want to sort the categories but let them take alphabetical order, give all male cats sort order 1 and female cats sort order 2. They will then form two sets of alphabetically-ordered cats.

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

    Default Re: Male/Female category sideboxes

    So you want the organization of the sidebox navigation to be completely different from the organization of the actual categories. That sounds like a bad idea to start. It will also require some custom coding somewhere.

    The categories sidebox will not show individual products without applying a separate (incompatible) mod.

  6. #6
    Join Date
    Aug 2009
    Posts
    9
    Plugin Contributions
    0

    Default Re: Male/Female category sideboxes

    I'll try using the sort order method. Every top level categorey has a male and female subcategory so that will allow me to seperate between the two.

    You could be right thought and maybe it more trouble than it's worth, but I'll give it a go and find out. Ithink I'll have to replicate and extend category_row.php to only display subcategories with sort order 0 (male) and female (1).

    I found some variable documentation here by the way might be useful for someone viewing this:

    http://phpxref.com/xref/zencart/_variables/index.html

  7. #7
    Join Date
    Aug 2009
    Posts
    9
    Plugin Contributions
    0

    Default Re: Male/Female category sideboxes

    I have managed to get back to working out this problem and have come up with a solution but still need some advice.

    I have created two ezpages for male and female categories and have followed this thread to allow them to support php:

    http://www.zen-cart.com/forum/showthread.php?t=37252

    I have given all male categories a sort order of 0 and all female categories a sort order of 1.

    I am using sql to get the male and female categories for each page and am using the categories_row.php page as a template to generate the HTML to display. My code looks like this:

    PHP Code:
    $sql "SELECT * FROM zen_categories WHERE parent_id != 0 AND sort_order=1 ORDER BY parent_id ASC;";

    $categories_list $db->Execute($sql); 

    if (
    $categories_list->RecordCount() > 0) { //if categories are returned from the SQL
        
    while (!$categories_list->EOF) {
        
            
    // Female categories have a sort order of 0    
            
               // if (!$categories_list->fields['categories_image']) !$categories_list->fields['categories_image'] = 'pixel_trans.gif';
                
    $cPath_new zen_get_path($categories_list->fields['categories_id']);
            
                
    // strip out 0_ from top level cats
                
    $cPath_new str_replace('=0_''='$cPath_new);
        
        
    $list_box_contents[$row][$col] = array('params' => 'class="categoryListBoxContents"' ' ' 'style="width:' $col_width '%;"',
                                               
    'text' => '
                                               
            <table style="width:1px; margin:auto;" align="center";>
                <tr>
                    <td>
    <div class="img_box">
       
                                               <a href="' 
    zen_href_link(FILENAME_DEFAULT$cPath_new) . '">' zen_image(DIR_WS_IMAGES .zen_get_categories_image($categories->fields['parent_id']), $categories->fields['categories_name'], SUBCATEGORY_IMAGE_WIDTHSUBCATEGORY_IMAGE_HEIGHT) . '</a>
       
        </div>
        <br class="clearBoth" />
        

                                               <a href="' 
    zen_href_link(FILENAME_DEFAULT$cPath_new) . '">' $categories->fields['categories_name'] . '</a><br /><br />                    
                    </td>
                </tr>
            </table>
            <br />
    '
    );

            
    $col ++;
            if (
    $col > (MAX_DISPLAY_CATEGORIES_PER_ROW -1)) {
              
    $col 0;
              
    $row ++;
            }
            
    $categories_list->MoveNext();
        }

    I have the $list_box_contents array, but am not sure how to use it. How do I actually output the HTMl for the categories?

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

    Default Re: Male/Female category sideboxes

    You have been talking about a number of different display areas and organizations: the categories sidebox, the category index page and possibly the product listing.

    Which do you really want to use? You say you want the existing category organization (topic cat > male/female subcats) to stay as is. That means the category index stays the same.

    You say you want the categories sidebox to be organized differently. That could be done by adding a new loop around the main loop to cycle through the categories twice, once selecting and outputting male subcat names and again selecting and outputting female subcat names to display in the sidebox. A question you may not have considered: how are all of these "Male" subcats going to be identified as to topic? If the subcat name is "Male" in each case, you need to do something to avoid confusion. Replacing the subcat names (using Categories Dressing features) with images unique to each subcat having relevant text in the image might work. Renaming the "Male" subcats to "Male Shirts" etc. might also work.

    Your latest post talks about reorganizing the category index page. Are you not going to display the categories as the original organization shows?

  9. #9
    Join Date
    Aug 2009
    Posts
    9
    Plugin Contributions
    0

    Default Re: Male/Female category sideboxes

    Sorry for the confusing posts, I was trying to get my head around the concept and was trying different ideas along the way.

    I have figured out what I wanted now. What I've done is use ezpages (with php enabled) to create male and female links in the top horizontal menu, each page just displays male or female products.

    I haven't changed the category organisation from my first post, just added another method of presentation.

 

 

Similar Threads

  1. Custom Sideboxes - category
    By johno22 in forum Customization from the Admin
    Replies: 1
    Last Post: 28 Apr 2009, 06:06 PM
  2. multiple category sideboxes
    By JohnBoyCR in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 15 Jan 2009, 07:16 PM
  3. extra category sideboxes?
    By smithers2005 in forum Basic Configuration
    Replies: 3
    Last Post: 4 Mar 2008, 07:27 PM
  4. Multiple Category Sideboxes
    By IncrediBody.com in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 1 Aug 2007, 05:38 AM
  5. two category sideboxes
    By fakeDecoy in forum Templates, Stylesheets, Page Layout
    Replies: 9
    Last Post: 30 Apr 2007, 04:09 AM

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