Originally posted by JSnow
Announcement
Collapse
No announcement yet.
Showing out of stock on below thumbnail
Collapse
X
-
Originally posted by budgetbumpswhich is what I said!
I was a bit nervous in the begining. Buggering it up, breaking actinic, blowing a crater into the crust of the earth, that sort of thing. Getting the hang of it now though.
More challenges please."Opportunities multiply as they are seized." - Sun Tzu
Comment
-
Hi guys,
Sorry to bring this up again after such a long time, but I never did get it working the way I wanted. I've got it working with the stock levels showing (numbers) see this page:
http://www.snugglefeet.com/shoes-for...-6-months.html
But all I really want is it simply to say 'Out of Stock' if below 1 and not show stock numbers. I did try the other versions of the code from this post but they didn't work.
Can anyone help?
Comment
-
Get your blockif(s) as close as you can get them and we can then correct things from there. For starters the whole area needs wrapping in a blockif that checks to see if stock level is not 1. That will show the details you want, you will then need another blockif which adds OOS message if it is 1. You cannot do an else/if type of thing with blockifs so need to do 2 completely separate ones, which collectively cover all scenarios. It will only ever show one message of the two.
Comment
-
as lee said, all you need is something like:
Code:<actinic:block if="%3cactinic%3avariable%20name%3d%22StockLevel%22%20%2f%3e%20%20%3c%3d%200"> Out of Stock </actinic:block>
If you want to only show an add to cart button if stock level is 1 or more:
Code:<actinic:block if="%3cactinic%3avariable%20name%3d%22StockLevel%22%20%2f%3e%20%20%3e%3d%201" > INSERT YOUR CART BUTTON LAYOUT HERE </actinic:block>
Comment
-
Can you confirm where you are adding this to Les, is it the section link layout or the product layout or neither? It will need to go into the individual layout you are using. Can you let us know the basic structure on how you have things, SPP using section and products or SPP using products and extended info pages?
Comment
-
Have you added the OOS blockif into the section link layout and then it shows all products on that page OOS? I think if it does something globally it more likely to be a coding problem, than a fault in the functionality, but i may be wrong as i have only ever shown stock messages in product layouts. It may need to be included into the ProductList block.
Can you provide your section link layout code in its entirety, enclose it in code tags though in your post.
Comment
-
Ah - as lee says, you'll need to put it in a ProductList block:
Code:<actinic:block type="ProductList" > <actinic:block if="%3cactinic%3avariable%20name%3d%22StockLevel%22%20%2f%3e%20%20%3c%3d%200"> Out of Stock </actinic:block> </actinic:block>
[EDIT]
I note in post #23 you have "OutOfStock" as the variable - the reason this doesn't work and shows everything as out of stock is that "OutOfStock" is not an Actinic variable - so it will always be zero! The variable you need is called "StockLevel"
[/EDIT]
Comment
-
Hi Lee and Dallen,
Many many thanks. The code from Dallen works.
Thanks to a great forum and members!
See code working....
http://www.snugglefeet.com/shoes-for...-6-months.html
Comment
-
Nice one Les, your next challenge is to change the OOS message as it can kill a sale instantly and link it through to your back ordering details, maybe with text 'available to back order' or alike. I particularly liked the way you handle these on your site and thought it was a very good idea what you do.
Comment
-
Originally posted by lessharma View PostThanks for your reply. Yes item is 'out of stock'.
The only code that works well is the first code from Jsnow. Shows the stock level in numbers. But all I want is to show the items out of stock.
Anymore ideas?
Also, I noticed that it marks all the products that do not have the stock monitoring checkbox ticked as out of stock too. Does anyone know how to get round this?
Thanks,
Matt
Comment
-
OK, I managed to get it working by tricking Actinic. I enabled stock monitoring on all the products that did not need stock monitoring and changed the etimated stock in hand to 30 (random number) then I disabled stock monitoring again. The quantity of 30 stays (although greyed out) and all of the products are back in stock!
My next question is: is there a way I can change the estimated stock in hand value from the default 0 to a higher number (for example 30) permanently? (i.e. make 30 my default value for estimated stock in hand for every new product I will add in the future?)
Thanks in advance for all your help.
Matt
Comment
Comment