Results 1 to 8 of 8
  1. #1
    Join Date
    Feb 2008
    Posts
    40
    Plugin Contributions
    0

    Default How to make category not show on search?

    On my website I have a Sold Items category qhere I put the items aftey they were sold. Everytime somebody search for something the products from the Sold Items category show up also but I dont want them to show up. How would I do it?

  2. #2
    Join Date
    Feb 2006
    Location
    Chicago
    Posts
    1,162
    Plugin Contributions
    0

    Default Re: How to make category not show on search?

    I dont know if there is a direct way to do it but you can modify the search related file to not include the products in the search results which are sold
    Tutorials on Zen Cart
    http://tutorials.zen-cart.com/index.php
    ---------------
    advanced.programmer at gmail dot com
    In love with Zen Cart!!

  3. #3
    Join Date
    Feb 2008
    Posts
    40
    Plugin Contributions
    0

    Default Re: How to make category not show on search?

    How can I do that?

  4. #4
    Join Date
    Feb 2006
    Location
    Chicago
    Posts
    1,162
    Plugin Contributions
    0

    Default Re: How to make category not show on search?

    Replace this line

    Code:
    $where_str = " WHERE (p.products_status = 1
                   AND p.products_id = pd.products_id
                   AND pd.language_id = :languagesID
                   AND p.products_id = p2c.products_id
                   AND p2c.categories_id = c.categories_id ";
    with this
    Code:
    $where_str = " WHERE (p.products_status = 1
    			   AND p.products_quantity > 0
                   AND p.products_id = pd.products_id
                   AND pd.language_id = :languagesID
                   AND p.products_id = p2c.products_id
                   AND p2c.categories_id = c.categories_id ";
    Please take the backup before you make this change
    Tutorials on Zen Cart
    http://tutorials.zen-cart.com/index.php
    ---------------
    advanced.programmer at gmail dot com
    In love with Zen Cart!!

  5. #5
    Join Date
    Feb 2006
    Location
    Chicago
    Posts
    1,162
    Plugin Contributions
    0

    Default Re: How to make category not show on search?

    includes/modules/pages/advanced_search_result/advanced_search_result/header_php.php
    Tutorials on Zen Cart
    http://tutorials.zen-cart.com/index.php
    ---------------
    advanced.programmer at gmail dot com
    In love with Zen Cart!!

  6. #6
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,622
    Plugin Contributions
    123

    Default Re: How to make category not show on search?

    Wait a minute .... instead of just moving the items to the sold category, why not just mark them sold out? (or both?)
    That way you wouldn't need to modify any code.
    That Software Guy. My Store: Zen Cart Modifications
    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.

  7. #7
    Join Date
    Feb 2008
    Posts
    40
    Plugin Contributions
    0

    Default Re: How to make category not show on search?

    Thanks superprg, that worked. swguy if I do that it will still have the sold out items in the category with the items for sale. I want to have all the sold ones separate.

  8. #8
    Join Date
    Aug 2005
    Location
    Vic, Oz
    Posts
    1,905
    Plugin Contributions
    5

    Default Re: How to make category not show on search?

    Quote Originally Posted by Punkristo View Post
    Thanks superprg, that worked. swguy if I do that it will still have the sold out items in the category with the items for sale. I want to have all the sold ones separate.
    Why not have the soldout category disabled that way no one will find them?

    or am I missing something here???

 

 

Similar Threads

  1. how to make the attribute's value show horizontally ,not Vertically
    By win8win in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 13 Oct 2012, 11:17 AM
  2. Replies: 11
    Last Post: 15 Aug 2011, 01:16 PM
  3. How do I make subcats not show on center page?
    By bettysue in forum Customization from the Admin
    Replies: 8
    Last Post: 25 Feb 2010, 12:27 PM
  4. How to make top category to show products instead of sub-categories?
    By MKdiable in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 12 Oct 2009, 11:55 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