Results 1 to 10 of 15

Hybrid View

  1. #1
    Join Date
    Jun 2008
    Posts
    255
    Plugin Contributions
    0

    Default Showing product ID number

    Hi,

    Is there a way to show the product's ID number on the product listing? or else have the model # automatically count like the ID number?

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

    Default Re: Showing product ID number

    You could customize the product_listing.php module and add the products_id where you want to see it with the:
    $listing->fields['products_id']
    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: v1.5.5]
    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!

  3. #3
    Join Date
    Jun 2008
    Posts
    255
    Plugin Contributions
    0

    Default Re: Showing product ID number

    Hello Alej,

    Thanks for the advice.

    I pulled up the products_listing.php under includes/modules and thought it would be easier to replace the 'products_model' into 'products_id' on line 93 where:

    switch ($column_list[$col]) {
    case 'PRODUCT_LIST_MODEL':
    $lc_align = '';
    $lc_text = $listing->fields['products_id']; <<--this is where I replaced it.
    break;

    Turned 'model no' on under the product listing admin but it does not show up on the product info.

    I must be replacing it in the wrong place??

    Any pointers please?

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

    Default Re: Showing product ID number

    Works fine for me ...

    What does show in that column?

    NOTE: You should use the templates and overrides:
    /includes/modules/your_template_dir/product_listing.php
    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: v1.5.5]
    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!

  5. #5
    Join Date
    Jun 2008
    Posts
    255
    Plugin Contributions
    0

    Default Re: Showing product ID number

    Yes, the changes were made on the modules/mytemplate.

    Now it shows the Model. without the products_id number.

    I went to tpl_document_products_display_info and changed:

    <!--bof Product details list -->

    <?php if ( (($flag_show_product_info_model == 1 and $products_model != '') or ($flag_show_product_info_weight == 1 and $products_weight !=0) or ($flag_show_product_info_quantity == 1) or ($flag_show_product_info_manufacturer == 1 and !empty($manufacturers_name))) ) { ?>

    <ul id="productDetailsList" class="floatingBox back">

    <?php echo (($flag_show_product_info_model == 1 and $products_model !='') ? '<li>' . TEXT_PRODUCT_MODEL . $products_model . '</li>' : '') . "\n"; ?>


    TO

    <?php if ( (($flag_show_product_info_model == 1 ) or ($flag_show_product_info_weight == 1 and $products_weight !=0) or ($flag_show_product_info_quantity == 1) or ($flag_show_product_info_manufacturer == 1 and !empty($manufacturers_name))) ) { ?>

    <ul id="productDetailsList" class="floatingBox back">

    <?php echo (($flag_show_product_info_model == 1 ) ? '<li>' . TEXT_PRODUCT_MODEL . $products_id . '</li>' : '') . "\n"; ?>

    Removing the "and $products_model != '') clause and adding products_id where $products_model is.

    Now it shows the title "Model no:" without any number on it.

    Is there some other file I need to be tinkering with?

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

    Default Re: Showing product ID number

    I made no other changes to the product_listing.php to make mine show ...

    I cannot pinpoint why your changes are not working ...

    If you look at the file on the server that you uploaded, do you see the changes in it?
    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: v1.5.5]
    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!

  7. #7
    Join Date
    Aug 2012
    Location
    North Carolina
    Posts
    28
    Plugin Contributions
    0

    Default Re: Showing product ID number

    Hi, I'm trying to display product id in product listing pages.

    I read this post and I tried to change 'product_listing.php' in modules, but I couldn't...

    I don't know where I should change and where I can put this:

    $listing->fields['products_id'];

    could you give me more specific information that I could change?
    thanks

 

 

Similar Threads

  1. Product ID number not showing on invoice
    By RobvdPool in forum Managing Customers and Orders
    Replies: 14
    Last Post: 11 Apr 2012, 05:42 PM
  2. Showing Total Number of Product Listed
    By yosemirza in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 22 Jan 2010, 09:45 AM
  3. Product number showing on checkout email
    By JimmyV in forum Templates, Stylesheets, Page Layout
    Replies: 9
    Last Post: 31 Aug 2009, 06:16 PM
  4. Featured Product Listing - not showing model number
    By guerrilladigital in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 2 Oct 2008, 04:48 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