Page 1 of 2 12 LastLast
Results 1 to 10 of 19
  1. #1
    Join Date
    Apr 2005
    Posts
    103
    Plugin Contributions
    0

    Idea or Suggestion Product Description on front page

    How can i add the product description on the front page where my new products added and my featured products are? Also how can i extend the product title length if you look some of the tiltes are long and they get cut off where can i adjust this? www.wonderfultoyz.com

    EDIT: WARNING: Adult Site ...
    Last edited by Ajeh; 23 Dec 2006 at 03:38 PM. Reason: always include a warning as a curtesy to the forum about adult sites

  2. #2
    Join Date
    Apr 2005
    Posts
    103
    Plugin Contributions
    0

    Default Re: Product Description on front page

    Can anyone help with this?

  3. #3
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Product Description on front page

    The easiest method would be to use a function to get this:
    PHP Code:
    zen_get_products_description($product_id$_SESSION['languages_id']) 
    Note: due to the nature of products_description field and its contents it is best cleaned before displaying it ...

    PHP Code:
    zen_trunc_string(zen_clean_html(stripslashes(zen_get_products_description($products_id$_SESSION['languages_id']))), 150
    Where products_id would be the known products_id where you are trying to display the products description ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  4. #4
    Join Date
    Apr 2005
    Posts
    103
    Plugin Contributions
    0

    Default Re: Product Description on front page

    im not that good where i know what and where i make these changes im sorry can u explain a little more for ajeh?

  5. #5
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Product Description on front page

    And example would be on the:
    /includes/modules/new_products.php

    copy to your templates and overrides directory:
    /includes/modules/your_template_dir/new_products.php

    Find the line for:
    PHP Code:
        'text' => (($new_products->fields['products_image'] == '' and PRODUCTS_IMAGE_NO_IMAGE_STATUS == 0) ? '' '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' zen_image(DIR_WS_IMAGES $new_products->fields['products_image'], $new_products->fields['products_name'], IMAGE_PRODUCT_NEW_WIDTHIMAGE_PRODUCT_NEW_HEIGHT) . '</a><br />') . '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' $new_products->fields['products_name'] . '</a><br />' $products_price); 
    And change to:
    PHP Code:
        'text' => (($new_products->fields['products_image'] == '' and PRODUCTS_IMAGE_NO_IMAGE_STATUS == 0) ? '' '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' zen_image(DIR_WS_IMAGES $new_products->fields['products_image'], $new_products->fields['products_name'], IMAGE_PRODUCT_NEW_WIDTHIMAGE_PRODUCT_NEW_HEIGHT) . '</a><br />') . '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' $new_products->fields['products_name'] . '</a><br />' $products_price zen_trunc_string(zen_clean_html(stripslashes(zen_get_products_description($new_products->fields['products_id'], $_SESSION['languages_id']))), 150)); 
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  6. #6
    Join Date
    Apr 2005
    Posts
    103
    Plugin Contributions
    0

    Default Re: Product Description on front page

    did not work.....Parse error: syntax error, unexpected T_IF in /home/wonderf/public_html/includes/modules/new_products.php on line 1

  7. #7
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Product Description on front page

    Check around line 1 for spaces, blank lines, missing <?php ... or other assorted errors ...

    Or, start again ... you have a typo ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  8. #8
    Join Date
    Apr 2005
    Posts
    103
    Plugin Contributions
    0

    Default Re: Product Description on front page

    i copied exactly what you said to replace with>

    'text' => (($new_products->fields['products_image'] == '' and PRODUCTS_IMAGE_NO_IMAGE_STATUS == 0) ? '' : '<a href="' . zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' . $new_products->fields['products_id']) . '">' . zen_image(DIR_WS_IMAGES . $new_products->fields['products_image'], $new_products->fields['products_name'], IMAGE_PRODUCT_NEW_WIDTH, IMAGE_PRODUCT_NEW_HEIGHT) . '</a><br />') . '<a href="' . zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' . $new_products->fields['products_id']) . '">' . $new_products->fields['products_name'] . '</a><br />' . $products_price . zen_trunc_string(zen_clean_html(stripslashes(zen_get_products_description($new_p roducts->fields['products_id'], $_SESSION['languages_id']))), 150));

  9. #9
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Product Description on front page

    To make sure that there is no confusion, here is the code with the code before and after it:
    PHP Code:
        $products_price zen_get_products_display_price($new_products->fields['products_id']);

        
    $new_products->fields['products_name'] = zen_get_products_name($new_products->fields['products_id']);
        
    $list_box_contents[$row][$col] = array('params' => 'class="centerBoxContentsNew centeredContent back"' ' ' 'style="width:' $col_width '%;"',
        
    'text' => (($new_products->fields['products_image'] == '' and PRODUCTS_IMAGE_NO_IMAGE_STATUS == 0) ? '' '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' zen_image(DIR_WS_IMAGES $new_products->fields['products_image'], $new_products->fields['products_name'], IMAGE_PRODUCT_NEW_WIDTHIMAGE_PRODUCT_NEW_HEIGHT) . '</a><br />') . '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' $new_products->fields['products_name'] . '</a><br />' $products_price);

        
    $col ++; 
    This is changed to:
    PHP Code:
        $products_price zen_get_products_display_price($new_products->fields['products_id']);

        
    $new_products->fields['products_name'] = zen_get_products_name($new_products->fields['products_id']);
        
    $list_box_contents[$row][$col] = array('params' => 'class="centerBoxContentsNew centeredContent back"' ' ' 'style="width:' $col_width '%;"',
        
    'text' => (($new_products->fields['products_image'] == '' and PRODUCTS_IMAGE_NO_IMAGE_STATUS == 0) ? '' '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' zen_image(DIR_WS_IMAGES $new_products->fields['products_image'], $new_products->fields['products_name'], IMAGE_PRODUCT_NEW_WIDTHIMAGE_PRODUCT_NEW_HEIGHT) . '</a><br />') . '<a href="' zen_href_link(zen_get_info_page($new_products->fields['products_id']), 'products_id=' $new_products->fields['products_id']) . '">' $new_products->fields['products_name'] . '</a><br />' $products_price zen_trunc_string(zen_clean_html(stripslashes(zen_get_products_description($new_products->fields['products_id'], $_SESSION['languages_id']))), 150));

        
    $col ++; 
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  10. #10
    Join Date
    Apr 2005
    Posts
    103
    Plugin Contributions
    0

    Default Re: Product Description on front page

    i appreciate your help but everything you tell me dosent work i copied everything you told me and it will not work

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v151 Product Description Not Showing On Front End / Online Catalog
    By firstcapitalfirearms in forum General Questions
    Replies: 9
    Last Post: 23 Mar 2014, 03:15 PM
  2. v151 admin, I put html code at product description, but it shows text format at front page
    By peter888 in forum Templates, Stylesheets, Page Layout
    Replies: 23
    Last Post: 16 Dec 2013, 02:15 PM
  3. Replies: 2
    Last Post: 14 Dec 2013, 05:49 PM
  4. Removing Product description from front page only?
    By tilenk in forum General Questions
    Replies: 8
    Last Post: 5 Oct 2009, 05:18 PM
  5. Can I add description to products on front page?
    By malhyp in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 6 Dec 2008, 07:37 AM

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