You can’t with woocommerce_get_product_thumbnail()
, but this will give you the exact same result:
global $product;
$image_size = apply_filters( 'single_product_archive_thumbnail_size', 'woocommerce_thumbnail' );
$custom_alt="Put your custom alt text here.";
return $product ? $product->get_image( $image_size, [ 'alt' => $custom_alt ] ) : '';
Related Posts:
- Insert variations via woocommerce api [closed]
- Display order items names in WooCommerce admin orders list [closed]
- Remember page before login page, redirect to that page after login
- WooCommerce lost password reset flow not working with SendGrid (redirect loop)
- Get user payment details when payment successfully done in woocommerce [closed]
- How to assign specific attribute to variation for woocommerce product?
- How to change page via login as user and admin
- How to remove the sub-category from Woocommerce product URL
- Find woocommerce product ID by custom field value?
- how to use different page design for different category
- Getting WordPress database error Deadlock
- Is there a plugin available for recurring orders in Woocommerce? [closed]
- Woocommerce PHP site that shows table with orders from specific category
- How to get the webshop page in 2:nd language, with Polylang and Hyyan
- Subcategories not working when using shared base with custom taxonomy
- Auto generate user email while registration
- WooCommerce Cart Total Table chronology order change [closed]
- Woocommerce Update Order Notes Date
- Shipping Method does not inherit settings from the class
- My woocommerce checkout page and woocommerce setting page are not responding [closed]
- Woocommerce Shortcode custom orderby not working
- Switch position of short description and variations [closed]
- Overwrite ‘require’ in child-theme
- Get specific values in Woocommerce Rest API
- Javascript error when adding an item to the cart [closed]
- Woocommerce: Complex query in pre_get_posts [closed]
- How can I get all the woocommerce api orders [closed]
- Is it possible to update the total price on the checkout page in woocommerce from a custom field
- Customize WooCommerce Add To Cart Form Name [closed]
- Remove WooCommerce block styles
- Can’t find a product by SKU
- Weird strange letters appeared in all website links [duplicate]
- password_reset doesnt work
- How can I reference external attachments without breaking core WordPress files?
- Hide prices from certain category in woocommerce
- Check if a WooCommerce Order Item has a specific meta data key
- WooCommerce Cart Items
- Retrieve Data from Custom Endpoint
- Online wc-blocks-style.css rendering instead of the hosted wc-blocks-style.css
- Broken link additional images after moving server
- I have 3 types of prices in WP and I need to change price for each specific user role using hooks
- How do I display only the relevant attributes?
- How to hide “Shipping” label from Woocommerce cart page
- How to add php variable inside wc_enqueue_js(‘jQuery’) function?
- Show menu order field in quick edit
- Adapt shipping surcharge code [closed]
- How to access product’s meta data when deleting a WooCommerce product?
- How to remove the Sub category product URL Woocommerce
- WC_Structured_Data Class Causing Needless Translation
- Placing Lock Icon on WooCommmerce “Place Order” Checkout Button (WordPress ‘ignoring’ Changes…)
- How to Sync Woocommerce and CRM via External API
- Add sale count next to star rating in woocommerce single product page
- Format number to 2 decimal places
- Two e-commerce in two different folders of the same domain
- Random 503 and 504 errors
- How do i display zip code options during checkout [closed]
- Woocommerce language isn’t default language
- How set variation after filter in WooCommerce?
- Does anyone know a crowdsourcing plugin that can support the following use case?
- How to get products without tag?
- How to invoice Woocommerce customer the remainder balance amount for additional items to an already paid order
- WooCommerce – Show different terms and conditions for different user roles
- Display product thumbnail in Woocommerce email notifications
- Getting error in debug : price was called incorrectly. Product properties should not be accessed directly
- Woocommerce rounding cart totals with tax up
- WordPress user ID prefix
- Remove link for Woocommerce product tags
- WooCommerce Class dosen’t exist
- How to make product free for some customers and paid for others?
- WooCommerce – different icons for product categories
- WordPress returning “XHR” even when access keys are used
- mydomain.com/wp-login redirects to wordpress.com/wp-login
- WooCommerce Admin Only Email Hook
- Woocommerce – Dynamic Link to The Most Recently Added Product
- Custom access given to Admin dashboard
- WooCommerce, after moving reviews tab to under product description. If pagination link is clicked description is hidden
- Is it possible to hide certain products from displaying in the search results
- WordPress Woocommerce product-category info on one line [closed]
- Woocommerce display price without formatting [closed]
- woocommerce: get product detail form sku [closed]
- How to get products outside main loop in Woocommerce?
- WooCommerce shipping tax
- Login page so wide [closed]
- Update WooCommerce product price periodically
- Woocommerce – display all sold out products
- Woocommerce how to show most selling products by category
- AffiliateWP not calculating multiple quantities when using affwp_calc_referral_amount filter
- Hide a shipping method if cart total is higher than an amount
- error 500 in Back Office when using a woocommerce function in functions.php
- Send data to external websites when there is an update or create a post
- WordPress pointing animated GIF images with wrong file name upon upload (GIFs animation not working)
- How to update all products with same SKU prefixes when updating stock with CSV?
- What is the best and cheapest way to generate dashboards about conversions data and store users? [closed]
- Sort by price when price is set in multiple keys
- Add a custom code with custom link after add to cart for every product
- WooCommerce product permalink based on product’s current category
- Disable duplicate WC product category URLs
- how should i get products based on tags in woocommerce
- Add custom text to product category page
- Woocommerce permalink URL change in DB