Results 1 to 10 of 33

Hybrid View

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

    Default Re: traffic light stock level indicator

    What code did you use to do this?

    The code on the other link looks to be for the Product Listing and not the Product _info page ...
    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!

  2. #2
    Join Date
    Sep 2006
    Location
    United Kingdom
    Posts
    195
    Plugin Contributions
    0

    Default Re: traffic light stock level indicator

    i used the code from the link lol silly me

    so is ther any way to get it to work on the product info page?

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

    Default Re: traffic light stock level indicator

    Same concept but the products_id is based on (int)$_GET['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!]
    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
    Sep 2006
    Location
    United Kingdom
    Posts
    195
    Plugin Contributions
    0

    Default Re: traffic light stock level indicator

    ok now you lost me lol
    im not good with code
    i can alter bits here and there but i get lost on anything complicated or anything with smarty tags lol

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

    Default Re: traffic light stock level indicator

    PHP Code:
    <?php
    if (zen_get_products_stock((int)$_GET['products_id']) >1) {
    $zc_stock_level_image '' $products_quantity zen_image(DIR_WS_TEMPLATE_ICONS 'icon_status_green.gif'''1010) . '';
    }

    elseif (
    zen_get_products_stock((int)$_GET['products_id']) <1) {
    $zc_stock_level_image '' $products_quantity zen_image(DIR_WS_TEMPLATE_ICONS 'icon_status_red.gif'''1010) . '';
    }

    else {
    $zc_stock_level_image '' $products_quantity zen_image(DIR_WS_TEMPLATE_ICONS 'icon_status_yellow.gif'''1010) . '';
    }
    echo 
    'I SEE ' $zc_stock_level_image;
    ?>
    Put the final $zc_stock_level_image where you want to see the quantity and the dot ...
    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
    Sep 2006
    Location
    United Kingdom
    Posts
    195
    Plugin Contributions
    0

    Default Re: traffic light stock level indicator

    ok lets see how bad i can break my site lol
    here goes..............

  7. #7
    Join Date
    Sep 2006
    Location
    United Kingdom
    Posts
    195
    Plugin Contributions
    0

    Default Re: traffic light stock level indicator

    well that started well cant even fine the right file to edit
    where is the file located???????

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

    Default Re: traffic light stock level indicator

    Ok it works on the product info page. How do you get it to work on the product listing page. I tried everything.

    I just want it to show the icons on the page the green, yellow, red icons. i want it to show between the price and more info button?

    Can be seen here where i want to place it: http://dealz-r-us.com/index.php?main...ex&cPath=1_2_3

    Thank you

  9. #9
    Join Date
    Nov 2007
    Posts
    34
    Plugin Contributions
    0

    Default Re: traffic light stock level indicator

    The code works great! How can I show the dot without the number in stock. Just the image. I must be a little slow but I can't figure it out.

 

 

Similar Threads

  1. Traffic Light Units in Stock indicator
    By Digiblood in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 12 Jul 2011, 09:25 AM
  2. Stock Level Indicator installation
    By orien in forum All Other Contributions/Addons
    Replies: 2
    Last Post: 9 Aug 2010, 11:14 AM
  3. Stock level indicator, for stock by attributes controller
    By vandiermen in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 13 Nov 2008, 09:49 AM
  4. product page stock level indicator
    By dscott1966 in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 1 Oct 2008, 04:28 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