Results 1 to 6 of 6
  1. #1
    Join Date
    Nov 2010
    Posts
    16
    Plugin Contributions
    0

    Default Category Product List & All/New Product List (DISPLAY IS DIFFERENT)

    Having a bit of a problem, I have installed Three_ olumns grid for new and all products pages 0-1

    My site can be found at http://gbsa.tyrmida.co.za/shop

    I'm trying to get the product listing of the category pages to display like the product listing of all products and new products.

    Is anyone able to point me in the right direction? This is rather urgent.


    Thanks in advance.

  2. #2
    Join Date
    Feb 2005
    Location
    Lansing, Michigan USA
    Posts
    20,024
    Plugin Contributions
    3

    Default Re: Category Product List & All/New Product List (DISPLAY IS DIFFERENT)


  3. #3
    Join Date
    Nov 2010
    Posts
    16
    Plugin Contributions
    0

    Default Re: Category Product List & All/New Product List (DISPLAY IS DIFFERENT)

    Ye sorry, forgot to say that I'd installed that too, and still no such luck!? it works on All products and New products just not in the category product listing...

  4. #4
    Join Date
    Feb 2005
    Location
    Lansing, Michigan USA
    Posts
    20,024
    Plugin Contributions
    3

    Default Re: Category Product List & All/New Product List (DISPLAY IS DIFFERENT)

    That mod doesn't affect the New or All listings - just the main product listing. Make sure you installed the mod correctly, including the SQL patch, and have set the options in admin properly.

  5. #5
    Join Date
    Nov 2010
    Posts
    16
    Plugin Contributions
    0

    Default Re: Category Product List & All/New Product List (DISPLAY IS DIFFERENT)

    Ok, I managed to get it to display in the grid, however. I'd like it to be displayed exactly like it is in all products & new products.

    See below:

    Image A = Category List



    Image B = New Products/All Products


    I'll also include the code, maybe someone can help me out.

    PRODUCT LISTING CODE

    Code:
    <?php
    /**
     * Module Template
     *
     * @package templateSystem
     * @copyright Copyright 2003-2005 Zen Cart Development Team
     * @copyright Portions Copyright 2003 osCommerce
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: tpl_modules_product_listing.php 3241 2006-03-22 04:27:27Z ajeh $
     * UPDATED TO WORK WITH COLUMNAR PRODUCT LISTING 04/04/2006
     */
     include(DIR_WS_MODULES . zen_get_module_directory(FILENAME_PRODUCT_LISTING));
    ?>
    <div id="productListing">
    <?php
    // only show when there is something to submit and enabled
        if ($show_top_submit_button == true) {
    ?>
    <div class="buttonRow forward"><?php echo zen_image_submit(BUTTON_IMAGE_ADD_PRODUCTS_TO_CART, BUTTON_ADD_PRODUCTS_TO_CART_ALT, 'id="submit1" name="submit1"'); ?></div>
    <br class="clearBoth" />
    <?php
        } // show top submit
    ?>
    
    <?php if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) {
    ?>
    <div id="productsListingTopNumber" class="navSplitPagesResult back"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></div>
    <div id="productsListingListingTopLinks" class="navSplitPagesLinks forward"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, zen_get_all_get_params(array('page', 'info', 'x', 'y', 'main_page'))); ?></div>
    <br class="clearBoth" />
    <?php
    }
    ?>
    
    <?php
    /**
     * load the list_box_content template to display the products
     */
    if (PRODUCT_LISTING_LAYOUT_STYLE == 'columns') {
      require($template->get_template_dir('tpl_columnar_display.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_columnar_display.php');
    } else {// (PRODUCT_LISTING_LAYOUT_STYLE == 'rows')
      require($template->get_template_dir('tpl_tabular_display.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_tabular_display.php');
    }
    ?>
    
    <?php if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {
    ?>
    <div id="productsListingBottomNumber" class="navSplitPagesResult back"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></div>
    <div  id="productsListingListingBottomLinks" class="navSplitPagesLinks forward"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, zen_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></div>
    <br class="clearBoth" />
    <?php
      }
    ?>
    
    <?php
    // only show when there is something to submit and enabled
        if ($show_bottom_submit_button == true) {
    ?>
    <div class="buttonRow forward"><?php echo zen_image_submit(BUTTON_IMAGE_ADD_PRODUCTS_TO_CART, BUTTON_ADD_PRODUCTS_TO_CART_ALT, 'id="submit2" name="submit1"'); ?></div>
    <br class="clearBoth" />
    <?php
        } // show_bottom_submit_button
    ?>
    </div>
    
    <?php
    // if ($show_top_submit_button == true or $show_bottom_submit_button == true or (PRODUCT_LISTING_MULTIPLE_ADD_TO_CART != 0 and $show_submit == true and $listing_split->number_of_rows > 0)) {
      if ($show_top_submit_button == true or $show_bottom_submit_button == true) {
    ?>
    </form>
    <?php } ?>
    ALL PRODUCTS LISTING
    Code:
    <?php
    /**
     * Module Template
     *
     * Loaded automatically by index.php?main_page=products_all.<br />
     * Displays listing of All Products
     *
     * @package templateSystem
     * @copyright Copyright 2003-2007 Zen Cart Development Team
     * @copyright Portions Copyright 2003 osCommerce
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: tpl_modules_products_all_listing.php 6096 2007-04-01 00:43:21Z ajeh $
    
     This modification of above is by dweb on 20 July 2009 and is to be placed at 
     	includes/templates/CUSTOM/templates/tpl_modules_products_all_listing.php
     	where CUSTOM is the name of your template.
    
     */
    
      $group_id = zen_get_configuration_key_value('PRODUCT_ALL_LIST_GROUP_ID');
    
      if ($products_all_split->number_of_rows > 0) {
        $products_all = $db->Execute($products_all_split->sql_query);
        $row_counter = 0;
        while (!$products_all->EOF) {
          $row_counter++;
    
          if (PRODUCT_ALL_LIST_IMAGE != '0') {
            if ($products_all->fields['products_image'] == '' and PRODUCTS_IMAGE_NO_IMAGE_STATUS == 0) {
              $display_products_image = str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_IMAGE, 3, 1));
            } else {
              $display_products_image = '<a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '">' . zen_image(DIR_WS_IMAGES . $products_all->fields['products_image'], $products_all->fields['products_name'], IMAGE_PRODUCT_ALL_LISTING_WIDTH, IMAGE_PRODUCT_ALL_LISTING_HEIGHT) . '</a>' . str_repeat('', substr(PRODUCT_ALL_LIST_IMAGE, 3, 1));
            }
          } else {
            $display_products_image = '';
          }
          if (PRODUCT_ALL_LIST_NAME != '0') {
            $display_products_name = '<h3 class="itemTitle"><a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '">' . $products_all->fields['products_name'] . '</a></h3>' . str_repeat('', substr(PRODUCT_ALL_LIST_NAME, 3, 1));
          } else {
            $display_products_name = '';
          }
    
          if (PRODUCT_ALL_LIST_MODEL != '0' and zen_get_show_product_switch($products_all->fields['products_id'], 'model')) {
            $display_products_model = TEXT_PRODUCTS_MODEL . $products_all->fields['products_model'] . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_MODEL, 3, 1));
          } else {
            $display_products_model = '';
          }
    
          if (PRODUCT_ALL_LIST_WEIGHT != '0' and zen_get_show_product_switch($products_all->fields['products_id'], 'weight')) {
            $display_products_weight = TEXT_PRODUCTS_WEIGHT . $products_all->fields['products_weight'] . TEXT_SHIPPING_WEIGHT . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_WEIGHT, 3, 1));
          } else {
            $display_products_weight = '';
          }
    
          if (PRODUCT_ALL_LIST_QUANTITY != '0' and zen_get_show_product_switch($products_all->fields['products_id'], 'quantity')) {
            if ($products_all->fields['products_quantity'] <= 0) {
              $display_products_quantity = TEXT_OUT_OF_STOCK . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_QUANTITY, 3, 1));
            } else {
              $display_products_quantity = TEXT_PRODUCTS_QUANTITY . $products_all->fields['products_quantity'] . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_QUANTITY, 3, 1));
            }
          } else {
            $display_products_quantity = '';
          }
    
          if (PRODUCT_ALL_LIST_DATE_ADDED != '0' and zen_get_show_product_switch($products_all->fields['products_id'], 'date_added')) {
            $display_products_date_added = TEXT_DATE_ADDED . ' ' . zen_date_long($products_all->fields['products_date_added']) . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_DATE_ADDED, 3, 1));
          } else {
            $display_products_date_added = '';
          }
    
          if (PRODUCT_ALL_LIST_MANUFACTURER != '0' and zen_get_show_product_switch($products_all->fields['products_id'], 'manufacturer')) {
            $display_products_manufacturers_name = ($products_all->fields['manufacturers_name'] != '' ? TEXT_MANUFACTURER . ' <a href="' . zen_href_link(FILENAME_DEFAULT, 'manufacturers_id=' . $products_all->fields['manufacturers_id']) . '">' . $products_all->fields['manufacturers_name'] . '</a>'. str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_MANUFACTURER, 3, 1)) : '');
    
    
          } else {
            $display_products_manufacturers_name = '';
          }
    
          if ((PRODUCT_ALL_LIST_PRICE != '0' and zen_get_products_allow_add_to_cart($products_all->fields['products_id']) == 'Y') and zen_check_show_prices() == true) {
            $products_price = zen_get_products_display_price($products_all->fields['products_id']);
            $display_products_price = TEXT_PRICE . ' ' . $products_price . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_LIST_PRICE, 3, 1)) . (zen_get_show_product_switch($products_all->fields['products_id'], 'ALWAYS_FREE_SHIPPING_IMAGE_SWITCH') ? (zen_get_product_is_always_free_shipping($products_all->fields['products_id']) ? TEXT_PRODUCT_FREE_SHIPPING_ICON . '<br />' : '') : '');
          } else {
            $display_products_price = '';
          }
    
    // more info in place of buy now
          if (PRODUCT_ALL_BUY_NOW != '0' and zen_get_products_allow_add_to_cart($products_all->fields['products_id']) == 'Y') {
            if (zen_has_product_attributes($products_all->fields['products_id'])) {
              $link = '<a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '">' . MORE_INFO_TEXT . '</a>';
            } else {
    //          $link= '<a href="' . zen_href_link(FILENAME_PRODUCTS_ALL, zen_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $products_all->fields['products_id']) . '">' . zen_image_button(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT) . '</a>';
              if (PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART > 0 && $products_all->fields['products_qty_box_status'] != 0) {
    //            $how_many++;
                $link = TEXT_PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART . "<input type=\"text\" name=\"products_id[" . $products_all->fields['products_id'] . "]\" value=\"0\" size=\"4\" />";
              } else {
                $link = '<a href="' . zen_href_link(FILENAME_PRODUCTS_ALL, zen_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $products_all->fields['products_id']) . '">' . zen_image_button(BUTTON_IMAGE_BUY_NOW, BUTTON_BUY_NOW_ALT) . '</a>&nbsp;';
              }
            }
    
            $the_button = $link;
            $products_link = '<a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '">' . MORE_INFO_TEXT . '</a>';
            $display_products_button = zen_get_buy_now_button($products_all->fields['products_id'], $the_button, $products_link) . '<br />' . zen_get_products_quantity_min_units_display($products_all->fields['products_id']) . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_BUY_NOW, 3, 1));
          } else {
            $link = '<a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '">' . MORE_INFO_TEXT . '</a>';
            $the_button = $link;
            $products_link = '<a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '">' . MORE_INFO_TEXT . '</a>';
            $display_products_button = zen_get_buy_now_button($products_all->fields['products_id'], $the_button, $products_link) . '<br />' . zen_get_products_quantity_min_units_display($products_all->fields['products_id']) . str_repeat('<br clear="all" />', substr(PRODUCT_ALL_BUY_NOW, 3, 1));
          }
    
          if (PRODUCT_ALL_LIST_DESCRIPTION > '0') {
            $disp_text = zen_get_products_description($products_all->fields['products_id']);
            $disp_text = zen_clean_html($disp_text);
    
            $display_products_description = stripslashes(zen_trunc_string($disp_text, PRODUCT_ALL_LIST_DESCRIPTION, '<a href="' . zen_href_link(zen_get_info_page($products_all->fields['products_id']), 'cPath=' . zen_get_generated_category_path_rev($products_all->fields['master_categories_id']) . '&products_id=' . $products_all->fields['products_id']) . '"> ' . MORE_INFO_TEXT . '</a>'));
          } else {
            $display_products_description = '';
          }
    
    ?>
              <div class="new_products">
                  <?php
                    $disp_sort_order = $db->Execute("select configuration_key, configuration_value from " . TABLE_CONFIGURATION . " where configuration_group_id='" . $group_id . "' and (configuration_value >= 1000 and configuration_value <= 1999) order by LPAD(configuration_value,11,0)");
                    while (!$disp_sort_order->EOF) {
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_IMAGE') {
                        echo $display_products_image;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_QUANTITY') {
                        echo $display_products_quantity;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_BUY_NOW') {
                        echo $display_products_button;
                      }
    
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_NAME') {
                        echo $display_products_name;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_MODEL') {
                        echo $display_products_model;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_MANUFACTURER') {
                        echo $display_products_manufacturers_name;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_PRICE') {
                        echo $display_products_price;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_WEIGHT') {
                        echo $display_products_weight;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_DATE_ADDED') {
                        echo $display_products_date_added;
                      }
                      $disp_sort_order->MoveNext();
                    }
    
                    $disp_sort_order = $db->Execute("select configuration_key, configuration_value from " . TABLE_CONFIGURATION . " where configuration_group_id='" . $group_id . "' and (configuration_value >= 2000 and configuration_value <= 2999) order by LPAD(configuration_value,11,0)");
                    while (!$disp_sort_order->EOF) {
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_IMAGE') {
                        echo $display_products_image;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_QUANTITY') {
                        echo $display_products_quantity;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_BUY_NOW') {
                        echo $display_products_button;
                      }
    
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_NAME') {
                        echo $display_products_name;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_MODEL') {
                        echo $display_products_model;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_MANUFACTURER') {
                        echo $display_products_manufacturers_name;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_PRICE') {
                        echo $display_products_price;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_WEIGHT') {
                        echo $display_products_weight;
                      }
                      if ($disp_sort_order->fields['configuration_key'] == 'PRODUCT_ALL_LIST_DATE_ADDED') {
                        echo $display_products_date_added;
                      }
                      $disp_sort_order->MoveNext();
                    }
                    
          /*          if (PRODUCT_ALL_LIST_DESCRIPTION > '0') {
                      echo $display_products_description;
                    } */
    ?>
             </div>
    <?php
    		if ($row_counter==3) {
    			$row_counter = 0;
    			echo '<br class="clearBoth" />';
    		}
    		
    		$products_all->MoveNext();
        }
      } else {
      	echo TEXT_NO_ALL_PRODUCTS;   
      }
    ?>
    <br class="clearBoth" />
    Thanks Stevesh, appreciate the help.

  6. #6
    Join Date
    Nov 2010
    Posts
    16
    Plugin Contributions
    0

    Default Re: Category Product List & All/New Product List (DISPLAY IS DIFFERENT)

    Not sure if thats the code i should be looking at but yeah, any help would be greatly appreciated.

    Thanks

 

 

Similar Threads

  1. v151 collom all list product and new products
    By Gerrit1958 in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 20 Jul 2013, 12:41 PM
  2. New Product list is different from regular product list
    By elite supplement in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 17 Sep 2012, 12:43 AM
  3. Disabling New Products & Enabling All Products in Category List
    By JRayfield in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 31 Jan 2010, 04:49 PM
  4. Need to display Product ID in functions_general.php to edit Category List Showcase
    By vandiermen in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 9 Mar 2009, 03:25 AM
  5. make category product list look like new product list
    By loosefast in forum Templates, Stylesheets, Page Layout
    Replies: 8
    Last Post: 8 Jun 2007, 09:03 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