but it does not help – the inventory is still being reduced with product purchase.
Not really sure how to use the plugin, but here is a screenshot of what I have –
The page I need help with: [ redundant link removed ]
]]>but it does not help – the inventory is still being reduced with product purchase.
Not really sure how to use the plugin, but here is a screenshot of what I have –
]]>I need to be able to display on the product shop pages “only 4 left in stock” under each “Add to Cart” button preferably.
I have gone to WOocommerce/Settings/Products/Inventory / and set LOW STOCK THRESHOLD to 4.
Then after googling for days I have found this code and added to my functions.php code which seems to work and displays the “only 4 left in stock” underneath every product on the very last line which is what I wanted to achieve but need to move it up higher in the block closer to the “Add to Cart” button. It has placed itself on the very last line underneath the “Add to Wishlist” which is underneath the “Add to Cart” button.
add_action(‘woocommerce_after_shop_loop_item’,’bbloomer_show_stock_shop’, 10);
function bbloomer_show_stock_shop() {
global $product;
if ( $product->stock ) { // if manage stock is enabled
if ( number_format( $product->stock,0,”,” ) < 4 ) { // if stock is low
echo ‘<div class=”remaining”>Only ‘ . number_format($product->stock,0,”,”) . ‘ left in stock!</div>’;
}
}
I really don’t know HOW to move it up underneath the “Add to Cart” button or higher as I cannot seem to find the correct coding as I added the code into the functions.php file.
I am familiar with CSS but still can’t find the coding looking in the CSS Inspector on the site. Site is not yet live so I need to finalise and fix this little issue.
I will have to create some code to move it but don’t know the correct one to add. Anyone have any ideas on how I can achieve this ?
As currently it is only viewing as plain old text, and I would prefer to have it with some background and different colour text, but as I don’t know where to link the css code for that particular div element I’m a bit stuck.
Thanks
Kristin
Is there a plugin that is flexible enough to handle such a thing? If not, I’m thinking this would be some custom programming to hit the web service for the inventory list and sync the database with that.
Thanks.
]]>I’m relatively new to the world of WordPress and WooCommerce
I have essentially set up a wordpress ecommerce site, integrated WooCommerce, a payment gateway, set up a few products and am running a few transactional tests.
Question is, do I need another plugin to manage the inventory, returns, refunds side of the transactions or is there something I can do with the WooCommerce plugin ?
Thank you
Inderaj
]]>Also would need a little assistance in creating a php query for that info if anyone feels like receiving some karma.
Thank you.
]]>