Home › Forums › WoodMart support forum › The “In Stock” widget is not working on the product page.
The “In Stock” widget is not working on the product page.
- This topic has 24 replies, 2 voices, and was last updated 1 month ago by Luke Nielsen.
-
AuthorPosts
-
November 28, 2024 at 9:51 pm #617335
EcommerceParticipantHi,
All the themes and plugins are up to date. I want the “In Stock” widget to appear on the product page without stock tracking for my products. I added the relevant widget and activated the settings on the custom product layout page, but the feature is not reflecting on the product page. I’m sharing screenshots in the custom section—could you please check?November 29, 2024 at 7:48 am #617417
EcommerceParticipantAdditionally:
Could you check why the estimated delivery date is not showing on the product page, cart, and checkout pages? It was visible during the initial setup but has since disappeared.December 2, 2024 at 6:40 pm #618663
Luke NielsenKeymasterHello,
Please send the FTP access and confirm the permission for plugin deactivation.
Thank you for your time and patience.
Kind Regards
December 6, 2024 at 10:15 pm #620325
EcommerceParticipantI updated the theme to the latest version, but the issues I mentioned above are still not resolved. Could you check it, please?
I will share the details in a private message.December 7, 2024 at 1:17 am #620333
Luke NielsenKeymasterHello,
You sent the admin access, but I need the FTP access, could you please send it? Also, may I disable 3rd party plugins?
Thank you for your time and have a good day!
Kind Regards
December 7, 2024 at 9:26 pm #620473
EcommerceParticipantWe haven’t created an FTP user on our hosting provider yet. Is it mandatory to provide FTP access? Aren’t the admin credentials sufficient for the processes?
December 8, 2024 at 12:41 am #620485
Luke NielsenKeymasterHello,
With the FTP we will have access to the server files, thus the developer’s can investigate the issue properly.
Thank you for your time.
Kind Regards
December 8, 2024 at 1:34 pm #620525
EcommerceParticipantHello,
To help you address the issues more comfortably, I’ve created a “staging” site. This staging site is hosted on a subdomain, and I’m sharing its admin panel and FTP credentials with you. Feel free to deactivate plugins as needed. Additionally, if you could share how you resolved the issue—while keeping our company and product details confidential—we can apply the solution to our main site. The credentials have been shared in a private area.
December 9, 2024 at 2:31 pm #620814
EcommerceParticipantHas the relevant situation been checked?
December 9, 2024 at 6:38 pm #620956
Luke NielsenKeymasterHello,
Sorry for the delay.
I have sent it to the developer’s team and they are investigating it. As soon as I receive an answer, I will let you know.
Thank you for your time.
Kind Regards
December 10, 2024 at 11:15 am #621100
Luke NielsenKeymasterHello,
Add the code below into the functions.php file in your child theme:
add_filter( 'woocommerce_get_availability_text', function ( $availability, $product ) { if ( $product->is_in_stock() ) { $availability = __( 'In stock', 'woodmart' ); } return $availability; }, 10, 2 );
Clear the cache and recheck the issue.
Kind Regards
December 10, 2024 at 11:19 am #621102
EcommerceParticipantHi,
Will a patch be released for the related issue?
Additionally, is the provided code intended to display the stock status on the product page? There was also an issue with the estimated delivery dates not being displayed.December 10, 2024 at 11:23 am #621104
Luke NielsenKeymasterHello,
1. This is not a bug. WooCommerce itself doesn’t allow to show just the “In stock” label on the product page. Yes, the code will work for those products that have a quantity.
2. Clarify the issue with the Estimate delivery for a better understanding.
Kind Regards
December 10, 2024 at 11:27 am #621105
EcommerceParticipantHere’s the revised English translation:
When you check the products on my main site, shared in the private field, you cannot see the estimated delivery date on the product page. However, when you add the product to the cart or proceed to the checkout page, the estimated delivery dates become visible. Despite being defined for all products, the estimated delivery dates do not appear consistently across the website.
December 10, 2024 at 1:30 pm #621173
Luke NielsenKeymasterHello,
Edit your Estimate Delivery bundle and remove the Shipping related to Turkey – https://prnt.sc/j2eKV7JIj6K2 (leave that field as empty), then clear the cache and recheck the issue.
Kind Regards
- This reply was modified 1 month ago by Luke Nielsen.
December 10, 2024 at 1:54 pm #621190
EcommerceParticipantThank you for your support, only one issue remains. Could you share the steps I need to follow to activate the “stock available” feature on the individual product page as it appears in the grid views?
Attachments:
You must be logged in to view attached files.December 10, 2024 at 1:59 pm #621199
Luke NielsenKeymasterHello,
In order to show “stock available” feature on the individual product page, add the code below into the functions.php file in your child theme:
add_filter( 'woocommerce_get_availability_text', function ( $availability, $product ) { if ( $product->is_in_stock() ) { $availability = __( 'In stock', 'woodmart' ); } return $availability; }, 10, 2 );
Then clear the cache and check haw it works.
Kind Regards
December 10, 2024 at 2:18 pm #621211
EcommerceParticipantI cleared the cache by adding the code you provided, but the “in stock” information is not reflected on the product pages. Could you check the relevant details on our staging site, which I shared in a private field, and provide feedback?
December 10, 2024 at 3:16 pm #621223
Luke NielsenKeymasterHello,
Did you select the variations of the product? Here is a screenshot that the label is working – https://monosnap.com/file/G3dcc7uDZ45KlEpE7Jxc5MpUToNKwM
Simple product – https://monosnap.com/file/aMH15u3xOL0ytg00VP4vOAd42mH15k
Kind Regards
December 10, 2024 at 3:30 pm #621228
EcommerceParticipantI shared a sample product in the private area. Why is there a ‘2 units in stock’ note for this product group?
December 10, 2024 at 3:43 pm #621244
Luke NielsenKeymasterBecause you have enabled it there – https://monosnap.com/file/T2UzyEApRpRGuGePdrJ9rEIYVQj78d and at the same time defined a separate element – https://monosnap.com/file/mm2JCrFO1nUHZN3D7xOXoklRxwx2i6
Kind Regards
December 10, 2024 at 4:03 pm #621256
EcommerceParticipantWhat should I do? Should I remove the code I placed in the Function page and just leave the defined element?”
add_filter(
‘woocommerce_get_availability_text’,
function ( $availability, $product ) {
if ( $product->is_in_stock() ) {
$availability = __( ‘In stock’, ‘woodmart’ );
}return $availability;
},
10,
2
);December 10, 2024 at 4:12 pm #621266
Luke NielsenKeymasterHello,
Just disable it there – https://monosnap.com/file/T2UzyEApRpRGuGePdrJ9rEIYVQj78d and leave an appropriate element.
The provided code gives the ability to show that label on the product page because by default WooCommerce doesn’t allow to show it in the way as you see on the archive page – https://prnt.sc/nWkbiZA09zxD
Kind Regards
- This reply was modified 1 month ago by Luke Nielsen.
- This reply was modified 1 month ago by Luke Nielsen.
December 10, 2024 at 4:27 pm #621276
EcommerceParticipantIs it unnecessary to add the ‘product stock status’ feature within the container in the Items field? Is it enough to set the stock display status of the ‘add to cart’ item to ‘active’? Please check the images I sent in the private area, my mind is all mixed up. What I mean is, if activating the stock field inside the ‘add to cart’ alone is enough, then I’ll delete the other container?
December 10, 2024 at 5:24 pm #621305
Luke NielsenKeymasterYep, activating the stock field inside the ‘add to cart’ alone is enough, then you can remove that element.
Kind Regards
-
AuthorPosts
- You must be logged in to create new topics. Login / Register