Forums / Templates, Stylesheets, Page Layout / item listing & item description page

item listing & item description page

Locked

Views: 2,087

Results 1 to 10 of 10
This thread is locked. New replies are disabled.
7 May 2007, 8:37 PM
#1
xanfar avatar

xanfar

New Zenner

Join Date:
Apr 2007
Posts:
77
Plugin Contributions:
0

item listing & item description page

I have been trying to make the item listing page look more like the description page. For starters the description on the item listing gets truncated which is fine except it has none of the layout properties given to the actual description...

The link is:
http://www.sportsboardscentral.com/store/index.php?main_page=index&cPath=65

I would like to manipulate the separate parts of each item listing (price, ...more info, description) to be more like the details page.

http://www.sportsboardscentral.com/store/index.php?main_page=product_info&cPath=65&products_id=182

This has been bugging me for awhile so any help here would be great. Thank You in advance.

7 May 2007, 11:27 PM
#2
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: item listing & item description page

The length of the listing description can be set in Configuration> Product Listing > Display Product Description.

HTML is disabled in the listing because truncated text might cut off the end of a tag and mess up the display. If you set the display longer than you ever expect your descriptions to be, you can safely re-enable HTML using the directions in this thread.

You can also make different parts of your descrpition display in the listing page and the info page, to keep the length down in the listing, as described here.

You can get "handles" for the elements of each product listing as discussed in the Add CSS Classes for Table Columns thread.

8 May 2007, 1:37 AM
#3
xanfar avatar

xanfar

New Zenner

Join Date:
Apr 2007
Posts:
77
Plugin Contributions:
0

Re: item listing & item description page

Many thanks, you gave me a lot here so I will practice with the info you sent and get back to you. I'll post the results with the hope this will help others.

8 May 2007, 4:23 PM
#4
xanfar avatar

xanfar

New Zenner

Join Date:
Apr 2007
Posts:
77
Plugin Contributions:
0

Re: item listing & item description page

After further review I realized I wouldn't be able to post what I have accomplished so far but if anyone has these questions gjh42 has given some valuable information in the links provided. I haven't managed to accomplish the description dividing yet (more php than I am able to handle at the moment) but I'm learning. So far my other problems have been solved...thanks again gjh42...great links!!!!!!!!:D

If I could be a bother one last time in this thread. I have split the columns for individual manipulation and I was able to make my price red as hoped using one of the links providing this code:

.PRODUCT_LIST_PRICE {
color: #FF0000;
font-size: 20px;
text-align: left;
}

However this also turns the "max #" and the "Add" text to red.
My example is:
http://www.sportsboardscentral.com/store/index.php?main_page=index&cPath=65
Please scroll through all items to see examples:
My question is can I remove the "Max: 1" from the items and can I replace the "Add quantity" that remains on items with the ...more info option..

This is the only part I did not see in the threads you provided...I can't stress enough the thanks I have for the help provided.

9 May 2007, 4:41 PM
#5
xanfar avatar

xanfar

New Zenner

Join Date:
Apr 2007
Posts:
77
Plugin Contributions:
0

Re: item listing & item description page

I managed to get rid of the "Add" plus qty. section and have it replaced with the buy now button so I can live with that, however I can't seem to get rid of "Max:1" yet.
I could really use help with this one if anyone knows this answer...thanks

9 May 2007, 5:40 PM
#6
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: item listing & item description page

Using the Developers Toolkit, I find that the Max: is the value of PRODUCTS_QUANTITY_MAX_TEXT_LISTING which is defined in /includes/languages/your_template/english.php and used in /includes/functions/functions_prices.php. You could easily comment out the constant, but that would still leave the 1. You will have to look at the file to find how best to handle suppressing the whole thing. $check_max is probably it, but best to check first :)

Line #443 : $the_min_units .= ($the_min_units != '' ? '<br />' : '') . PRODUCTS_QUANTITY_MAX_TEXT_LISTING . ' ' . $check_max;

Line #445 : $the_min_units .= ($the_min_units != '' ? '  ' : '') . PRODUCTS_QUANTITY_MAX_TEXT_LISTING . ' ' . $check_max;

9 May 2007, 5:56 PM
#7
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: item listing & item description page

Note: I started by looking in tpl_product_info_display.php and finding no trace of max qty display, only min qty. It turns out that the max qty display is written into the min qty display and all output as one chunk.

So you could comment out the "min" there as long as you don't care about minimum quantities, and avoid editing the functions_prices file.

<!--bof Add to Cart Box  -gjh42 4/13/06 moved down from above  Product details list -->
<?php
if (CUSTOMERS_APPROVAL == 3 and TEXT_LOGIN_FOR_PRICE_BUTTON_REPLACE_SHOWROOM == '') {
  // do nothing
} else {
?>
            <?php
    $display_qty = (($flag_show_product_info_in_cart_qty == 1 and $_SESSION['cart']->in_cart($_GET['products_id'])) ? '<p>' . PRODUCTS_ORDER_QTY_TEXT_IN_CART . $_SESSION['cart']->get_quantity($_GET['products_id']) . '</p>' : '');
            if ($products_qty_box_status == 0 or $products_quantity_order_max== 1) {
              // hide the quantity box and default to 1
              $the_button = '<input type="hidden" name="cart_quantity" value="1" />' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
            } else {
              // show the quantity box  gjh42 4/13/06 - chg box layout to horiz. 20070507 - add button id
    $the_button = PRODUCTS_ORDER_QTY_TEXT . '<input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($_GET['products_id'])) . '" maxlength="6" size="4" />' . zen_get_products_quantity_min_units_display((int)$_GET['products_id']) . '<span id="cartAddButton">' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT) . '</span>';
            }

This may be the part to comment out:
zen_get_products_quantity_min_units_display((int)$_GET['products_id']) .

9 May 2007, 6:59 PM
#8
xanfar avatar

xanfar

New Zenner

Join Date:
Apr 2007
Posts:
77
Plugin Contributions:
0

Re: item listing & item description page

I have done some more experimenting. I have yielded absolutely no results. I even went as far as commenting out everything between

<!--bof Add to Cart Box -->

and

<!--eof Add to Cart Box -->

So far not even a slight change has occurred...what am I doing wrong??

10 May 2007, 6:29 AM
#9
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: item listing & item description page

Are you sure you're editing the right copy of the file? You should have a copy in /includes/templates/your_template/templates/tpl_product_info_display.

Are you sure you uploaded the file properly after editing? What has your procedure been?

10 May 2007, 3:47 PM
#10
xanfar avatar

xanfar

New Zenner

Join Date:
Apr 2007
Posts:
77
Plugin Contributions:
0

Re: item listing & item description page

I found what was going wrong. You were absolutely right about the file that I need to edit. I was also doing it the right way but I decided to enter the function call into the developer tools search just to see if it was being called anywhere else. And of course...it was...so I commented it out in this file as well:

/includes/modules/product_listing.php

In combination with the file you recommended...I got the results I needed.
Thank You...I couldn't have done it without the your help.