Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1
    Join Date
    Jan 2009
    Posts
    33
    Plugin Contributions
    0

    Default Make a page with a list of all subcategories

    Hi
    I would like to make a page to list all the sub categories. I can make a new page following these instructions http://www.zen-cart.com/wiki/index.p...ting_new_pages but I am not sure what to put in the header_php.php and the template file to do what I want. I assume I would have to add a query to the header and the results to show in the template.
    Can any one help??

    The page would look similar to the main page when you select the option to show categories on it, but I don't want it to be on the main page but a separate page.

    I have searched the forum and checked for plugins but can't find the answers I need. I also tried using the About Us page mod but the same problem is I don't know how to get what I want displayed.

    Any help greatly appreciated.

  2. #2
    Join Date
    Nov 2009
    Location
    In beautyful New York
    Posts
    160
    Plugin Contributions
    2

    Default Re: Make a page with a list of all subcategories

    look at the sitemap page (or 404)

  3. #3
    Join Date
    Jan 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Make a page with a list of all subcategories

    I still haven't figured out how to do this. Maybe if I explain a little better.

    Say I have a category called Ink, then I have subcategories Red, Blue, Yellow, etc. When I click on Ink now it shows the name and link of each subcategory. What I would like is to click on Ink and it shows all the products in all the subcategories for ink. It would look similar to clicking on the All Products link but instead of showing all products it only shows all products in the subcategories for that category .

    I have searched the forum often to see if I can find the answer and have seen the question but not the answer. One answer said I could use Simple Category Tree but I think this is only for the category menu not how or what it shows when I click on the link for a parent category.

    I thought I might need to make a page for each category then somehow make the category sidebox link to that page when the parent category is selected. But I don't know how. Although I am not a PHP expert I have a general understanding of it and I have adjusted code several times so I am not afraid to get my hands dirty so to speak.

    Can anyone either explain how to do this or point me in the direction of a plugin, if available?

    Any help greatly appreciated

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

    Default Re: Make a page with a list of all subcategories

    There is a thread or family of threads for "all products on main page" which has a number of related but different mods attached by various people for showing subcategories' products on a top category's page in one way or another.Somewhere in there you will find a solution or a base that can point you to it.

  5. #5
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    10,511
    Plugin Contributions
    126

    Default Re: Make a page with a list of all subcategories

    Have you looked at your shop's site map?

    YOURSTORE.com/index.php?main_page=site_map

    This sounds to me like what you want and it's already built in to Zen Cart.
    That Software Guy. My Store: Zen Cart Support
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

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

  7. #7
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    10,511
    Plugin Contributions
    126

    Default Re: Make a page with a list of all subcategories

    Glenn, I completely missed that the OP also wanted all products. Thanks.
    That Software Guy. My Store: Zen Cart Support
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  8. #8
    Join Date
    Jan 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Make a page with a list of all subcategories

    Hi Glenn Thanks for the link to that thread. It seems to be what I am looking for. I tried the latest files posted by McCrockett but after installing nothing happened. I noticed someone else (gameoverbeyond) had the same problem and asked the question Is this not compatible with 1.5.1? I am also using 1.5.1 could this be why it is not working?

    I will try one of the older versions and see if that makes a difference but if it is a compatibility problem how would I go about updating the files to work with 1.5.1?

    Thanks for your help.

  9. #9
    Join Date
    Jan 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Make a page with a list of all subcategories

    OK it seems to be displaying on the main page and I can also get it to work on the category page but it just seems to show all the products in all the categories. How do I make it only display the products from one parent category and it's sub category? I have read through the thread but I think I must have missed something.

    Your help is greatly appreciated.

  10. #10
    Join Date
    Jan 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Make a page with a list of all subcategories

    Sorry, I didn't realise there were two different mods being discussed in that thread. I used the zip file in post #29
    By the way here I attach the mod from yellow so you can check it out if you dont have it yet.

    Thanks so much Glenn!

    Attached Files

    File Type: zip all_sub_cats_products.zip (9.3 KB, 387 views)
    When I installed it I got a white blank page and could not see any of the site. I figured this was probably because it was made for an older version of Zencart so after a little digging around in the code I found a line of code that was different but similar in the header.php and after I changed this it all seems to be working.

    Here is what I changed:

    In includes/modules/pages/index/header_php.php

    Find this line of code;
    Code:
    require(DIR_WS_INCLUDES . zen_get_index_filters_directory($typefilter . '_filter.php'));
    and replace it with this:
    Code:
    require(zen_get_index_filters_directory($typefilter . '_filter.php'));
    Everything now seems to be working as it should, in 1.5.1 (I don't know much about the difference between the different versions so if you know of any other files that should have been changed please let me know).

    Here is how it works, I have a category called Ink, then I have subcategories Red, Blue, Yellow, etc. When I click on Ink now it shows all the products in all the subcategories for ink.

    Hopefully this might help someone else.

    Thanks for your help
    Last edited by enochian; 1 May 2013 at 07:57 AM.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Know how to make Categories Index Display All Products Within it's Subcategories?
    By makehveli in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 25 Aug 2011, 03:43 AM
  2. Creating separate page with list of all of the products
    By meesix in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 7 Apr 2010, 12:11 PM
  3. Additional Page with All Products in Alphabetical List
    By kgeoffrey in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 28 May 2009, 08:13 PM
  4. Make Subcategories show all the time
    By cinbou in forum Basic Configuration
    Replies: 6
    Last Post: 13 Sep 2008, 12:55 AM
  5. List all products with attributes on one page
    By busymum in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 9 Feb 2008, 03:34 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