fbpx
Want To Add Extra Images Per Product Variation For Free? Download Now

Add a word and styling to Clear button

Hi Ahmed Ehsaan

Please could you assist with the below:

Clear.JPG

I would like to add the word ‘SELECTION’ to the ‘CLEAR’ button under the swatches? it should be CLEAR SELECTION. I would like to add CSS to match the ADD TO CART button – font all CAPS, with a Red #ff3a3a Background and the writing colour #fff and spacing the same.

Please can you send me the code and let me know what file to add it too?

Thank you.

 

Tanvirul Haque

Hi Samantha Zwiegers,

I am the Lead Support Engineer of this plugin, Could you add me here on Skype? My Skype Id is: shovon.haque2

Please add me and say hi with your ticket ID. I am waiting for you there to quickly squash your issue.

Thank

Tanvirul Haque

Here is the PHP code, put those on your child-theme fuctions.php file:

add_action( 'woocommerce_reset_variations_link', function () {
echo '<a class="reset_variations" href="#">' . esc_html__( 'CLEAR SELECTION', 'woocommerce' ) . '</a>';
}, 15 );

And here is the CSS code, put those codes inside your child theme style.css file:

.woocommerce.single-product div.product form.cart .reset_variations {
color: #FFFFFF;
display: inline-block;
font-size: 13px;
font-weight: 300;
line-height: 1;
padding: 10px 15px 11px;
text-transform: uppercase;
background-color: #ff3a3a;
border-color: #ff3a3a;
font-family: "Poppins", sans-serif;
margin-top: 10px;
}

Is there anything else that I can help you with?

Thanks