Results 1 to 2 of 2

I want to show products in category listing

This is a discussion on I want to show products in category listing within the osCommerce 2.2 Modification Help forums, part of the osCommerce 2.2 Forums category; I would like to show products in the category listing rather than categories of products or sub-categories. So, when I ...

      
  1. #1
    Lurker
    Join Date
    Jan 2005
    Posts
    2
    Rep Power
    0


    Default I want to show products in category listing

    I would like to show products in the category listing rather than categories of products or sub-categories. So, when I click on a product in the category listing, I would like it to take me to the product page, and not the page that provides a listing of products.

  2. #2
    Lurker
    Join Date
    Jan 2005
    Posts
    2
    Rep Power
    0


    Default RE: I want to show products in category listing

    I'm new to osCommerce, and I realize the following is a hack, but I think it works. I realize that I will not be able to have sub-categories, which is what I want. Anyone see any implications elsewhere?


    I made the following changes/additions to categories.php:function tep_show_category to change the href for the categories.

    $cat_to_prod_query = tep_db_query("select products_id as prod_id from " . TABLE_PRODUCTS_TO_CATEGORIES . " where categories_id = '" . (int)$counter . "'");
    $cat_prod = tep_db_fetch_array($cat_to_prod_query);
    $products_id_new = '&products_id=' . $cat_prod['prod_id'];
    $cPath_new .= $products_id_new;

Similar Threads

  1. How to change number of columns inside category listing
    By shirster in forum osCmax v2 Customization/Mods
    Replies: 1
    Last Post: 05-17-2006, 03:45 AM
  2. new products-link show all products, not 10 as I configure..
    By mikkvais in forum osCommerce 2.2 Discussion
    Replies: 0
    Last Post: 08-23-2005, 02:31 PM
  3. I would like to show just 1 category in the menu at a time
    By thinkweb in forum osCommerce 2.2 Modification Help
    Replies: 0
    Last Post: 01-27-2005, 10:00 AM
  4. Modyfying product listing and new products listing
    By pavlo in forum osCommerce 2.2 Modification Help
    Replies: 0
    Last Post: 11-22-2004, 08:27 AM
  5. Help help help = Category listing output
    By Anonymous in forum osCommerce 2.2 Modification Help
    Replies: 5
    Last Post: 11-25-2002, 10:27 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
  •