Post by TheLegendP » Wed Sep 09, 2020 1:00 am

Hi,
Does anybody know a way to change the 'Add to cart' button to display the stock availability instead? ie In stock, 3-4 days etc.

I did have a look for the easy option of an extension, but couldn't see anything suitable.

Newbie

Posts

Joined
Thu Jul 02, 2015 11:00 pm

Post by letxobnav » Wed Sep 09, 2020 10:13 am

"Add to cart" is a function, "stock availability" is information, they do not mix.

Crystal Light Centrum Taiwan
Extensions: MailQueue | SUKHR | VBoces

“Data security is paramount at [...], and we are committed to protecting the privacy of anyone who is associated with our [...]. We’ve made a lot of improvements and will continue to make them.”
When you know your life savings are gone.


User avatar
Expert Member

Posts

Joined
Fri Aug 18, 2017 4:35 pm
Location - Taiwan

Post by khnaz35 » Wed Sep 09, 2020 11:09 am

TheLegendP wrote:
Wed Sep 09, 2020 1:00 am
Hi,
Does anybody know a way to change the 'Add to cart' button to display the stock availability instead? ie In stock, 3-4 days etc.
To change 'Add to cart' button text edit catalog/controller/language/en-gb.php

Find:

Code: Select all

$_['button_cart']           = 'Add to Cart';
Replace:

Code: Select all

$_['button_cart']           = 'In stock';
Just a question:
How your customers will know that what should i do next when they can see the item is in stock proceed to add to cart checkout :crazy: ???
Unless you put the button text like 'In stock Add to Cart Now etc'

Urgent Questions shoot here: khnaz35@gmail.com
Enjoy nature ;) :) :-*


User avatar
Active Member

Posts

Joined
Mon Aug 27, 2018 11:30 pm
Location - Malaysia

Post by letxobnav » Wed Sep 09, 2020 11:38 am

the only way this makes sense is if you do not have stock, disable the button and change the text to "no stock".
If you do have stock, just leave "add to cart", besides who cares how many you have in stock other than you.

Crystal Light Centrum Taiwan
Extensions: MailQueue | SUKHR | VBoces

“Data security is paramount at [...], and we are committed to protecting the privacy of anyone who is associated with our [...]. We’ve made a lot of improvements and will continue to make them.”
When you know your life savings are gone.


User avatar
Expert Member

Posts

Joined
Fri Aug 18, 2017 4:35 pm
Location - Taiwan

Post by TheLegendP » Wed Sep 09, 2020 9:32 pm

letxobnav wrote:
Wed Sep 09, 2020 10:13 am
"Add to cart" is a function, "stock availability" is information, they do not mix.
So your saying that the "add to cart" text can not display the stock status?

I know you can change the add to cart to anything you want, but I thought there would have been a way to change it to display the availability of a product (as it does for example if a product is out of stock).

The reason I want to change it is simply because some items are in stock for immediate dispatch, and others are a special order. Although it does display this on the product page under availability, I would rather it also displayed it as part of the add to cart button, so it was clear if the product was in stock or a special order.

Newbie

Posts

Joined
Thu Jul 02, 2015 11:00 pm

Post by pprmkr » Thu Sep 10, 2020 12:47 am

See demo ....

If product['quantity'] < 1 it shows image in corner with stock status text. Also checks in cart Add if product quantity > 0. If not in stock, add to cart button in modules redirect to product page. There Add to cart button displays stock status text and is disabled.
Last edited by pprmkr on Mon Dec 07, 2020 10:26 pm, edited 1 time in total.

User avatar
Active Member

Posts

Joined
Sat Jan 08, 2011 11:05 pm
Location - Netherlands

Post by khnaz35 » Thu Sep 10, 2020 12:52 am

pprmkr wrote:
Thu Sep 10, 2020 12:47 am
See demo. Also see category 'Presents' ...

If product['quantity'] < 1 it shows image in corner with stock status text. Also checks in cart Add if product quantity > 0. If not in stock, add to cart button in modules redirect to product page. There Add to cart button displays stock status text and is disabled.
Nice work :)

Urgent Questions shoot here: khnaz35@gmail.com
Enjoy nature ;) :) :-*


User avatar
Active Member

Posts

Joined
Mon Aug 27, 2018 11:30 pm
Location - Malaysia
Who is online

Users browsing this forum: No registered users and 261 guests