$product_id = $product->get_id();
// Reemplaza 'your_attachment_meta_key' con la clave real utilizada por el plugin
$wcpoa_attachment_url_arg = 'your_attachment_meta_key';
$file_id = get_post_meta($product_id, $wcpoa_attachment_url_arg, true);
// Define el botón de "COTIZACIóN" con la URL de descarga del archivo PDF
if (!empty($file_id)) {
// Obtén la URL de descarga del archivo adjunto
$file_url = wp_get_attachment_url($file_id);
]]>Is there a snippet or a link you could help me with?
Thanks for the help in advance
i want to change button icon according to my theme design. i found custom button option but dont know how to put own designed icon over there…
Thanks
]]>I would like to create a button next to add to cart titled buy branded. I would like this button to redirect to a form where my customers can input color, size, branding position, branding type and also upload artwork and that form should be then emailed to my email address. Please kindly assist, how do I go about this? The whole objective is to allow customers who prefers the products I sell branded to submit their branding request. This means the form should also collect email address, phone number, and customer name
]]>I’ve been searching and reading the docs for a while and I did a lot of tests, but just can’t resolve this issue. I’m pretty aware of why it’s happening, but can’t resolve it all by myself.
I’ve made a site with Oxygen builder, so it has a lot of custom code and some of the Woocommerce pages are custom made. And that’s why I have a problem in the first place. I know that. Some hooks aren’t fired natively and maybe some classes are missing from the Add To Cart buttons or product wrappers.
The problem is that product details are missing in the dataLayer when the add_to_cart event fires. So, I am seeing events, that is OK, but the values are missing (item_id value, item_name value, etc.). It’s probably because I can’t “call” class: gtm4wp_productdata with all that data about the product.
You can check it on https://pokanails.com/shop/.
I’ve read this guide https://gtm4wp.com/how-to-articles/how-to-make-your-wordpress-theme-compatible-with-enhanced-ecommerce-tracking and tried to implement the WC actions and filters on e.g. Shop page or on the Single Product page, but without luck. I don’t know where to put it on the page. And which ones. When I put this hook: woocommerce_after_add_to_cart_button just after Add To Cart button, nothing happens on the front end, but I see some error notice inside my builder and it’s related to this plugin. So, probably I’m on the right track, but don’t know how to implement it properly.
On the other side, I didn’t tweak a lot the Cart page, so adding and removing products there is properly set up in dataLayer.
Can anyone push me in the right direction in this case? Thank you in advance!
]]>