Home Forums WoodMart support forum After 'Add to cart' button content

After 'Add to cart' button content

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #266322

    atpd23
    Participant

    Hello,

    In Theme Settings > Product page I can set custom after ‘Add to cart’ button content by HTML blocks. That’s what I need to, but not to keep the same HTML block for all product pages. What I would rather need to achieve is individual HTML block for every product page. I mean, I would like to highlight in 2-3 lines product features exactly after the ‘Add to cart’ button and it means, I would need to create individual HTML blocks, not a general one used for all product pages by Theme Settings.

    Best Regards

    #266421

    Hello,

    In this case, you would better consider using Extra content on the product page: https://xtemos.com/docs/woodmart/html-blocks-2/#extra_content_options

    The content would not be placed right after adding to cart button, however, it is the option to add individual content in to the product page.

    Best Regards

    #266457

    atpd23
    Participant

    Hello,

    Thanks for the fast response. Extra content is the way, unfortunately as you’ve mentioned, it doesn’t place right after adding to cart button, what is exactly I need to.

    If that feature isn’t possible in WoodMart, could I ask you to give me some clue how to do it by myself? In the image is shown, what I would like to achieve.

    Best Regards

    Attachments:
    You must be logged in to view attached files.
    #266627

    Hello,

    Please add this code to the functinons.php of the child theme and the extra content block would move after Add to cart.

    add_action(
    	'wp',
    	function() {
    		remove_action( 'woodmart_after_product_content', 'woodmart_product_extra_content', 20 );
    		add_action( 'woocommerce_single_product_summary', 'woodmart_product_extra_content', 31 );
    	},
    	1200
    );

    Best Regards

    #266854

    atpd23
    Participant

    Hello,

    Great, it works, thank you! Please and how could I set a border/shadow for desired elements in product page summary? I would like to separate some elements like quantity, price and button. To do that, to apply CSS style, I guess it’s necessary to set a container for that elements, but don’t know how.

    In the image border.jpg you can clearly see what I mean.

    Best Regards

    Attachments:
    You must be logged in to view attached files.
    #266954

    Hello,

    Please add this code to the Theme Settings > Custom CSS > Global:

    body.single-product .woocommerce-variation-add-to-cart{
    padding:7px 0  0 7px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.4);
    }

    Best Regards

    #267168

    atpd23
    Participant

    Hello,

    It’s working, but only for variable products. Also, it borders only quantity field and add to cart button, not the price as is shown in the image border.png – there is shown desired effect.

    I have moved the price from default position to above the add to cart button and I would like to add there the border. Maybe it’s needed to give all that three elements into an container, but don’t know how – also in this way, it would be very useful if I had to give into border some more elements, let’s say some meta values. Therefore it would be great if something like that (adding container into desired elements) would be possible, because of flexibility in the future.

    Best Regards

    #267396

    Hello,

    Please provide your product page URL and show the screen of what you want to do on your product pages.

    Best Regards

    #267443

    atpd23
    Participant

    Hello,

    The website is located on my testing server, so I am sending IP address in the private content.

    In the attach image you can see the actual look and I would need to border the selection – not only the quantity field and add to cart as your previous code does, but also the price (I have moved the price to different position, it’s not the default one).

    Best Regards

    Attachments:
    You must be logged in to view attached files.
    #267679

    Hello,

    Unfortunately, it is not possible to make shadows as you show. These blocks are different and shadow is applied to the integral block.

    Best Regards

    #267737

    atpd23
    Participant

    Hello,

    Isn’t there a way to add starting class tag before the price and ending class tag after the add to cart button and then apply style (border) to that class?

    Best Regards

    #267832

    Hello,

    There is no option to add any classes, that would require complicated customization that is not covered by our support.

    Best Regards

Viewing 12 posts - 1 through 12 (of 12 total)