I have a button that I’d like to customize differently than what I’ve set the global buttons. I added the button and modified it but there is no option for editing the hover color of the button so I am trying to write additional CSS for it.
I set up a new class for the button
Custom-Button-Orange-to-Purple
but when I try to add the additional styling to this element (I did try and set up the class without the :hover and that didn’t work either).
.Custom-Button-Orange-to-Purple:hover {
background-color:#8601AF !important;
border-color:none !important;
}
The button I’m trying to modify is the orange one at the bottom of the page here: Kidz Haven Daycare . The code changes the border of the button to purple which I don’t want.
I’m new to adding custom CSS (obviously) and would be grateful for some help!
2
Answers
This took a full days worth of hunting and trying different methods. What I did was to get rid of the class name I had added to the "Advanced" tab where I created the custom button. Instead I added HTML to the block on the page where the button would appear. I used a div container as well to be able to center it on the page.
HTML added to the block with new class names:
WHY KIDS HAVEN DAYCARE
ADDITIONAL CSS:
I'm not certain if I "needed" to use the !important but given the amount of time it took to figure this out, I figured it was better safe than sorry!
Thanks for the responses. I'm a total newbie, so some comments were over my
This is what your CSS looks like, which is absolutely wrong:
Also, there is no element with the class
Custom-Button-Orange-to-Purple
.This is what I understand from your question: You have customized the style of usual buttons, and now you want to style a button which should look different. If so, this may help: