Hướng dẫn css active after click
Once the button is clicked I want it to stay with the active style instead of going back to normal style. Can this be done with CSS please? Im using blurb button from DIVI Theme (WordPress). Please help me! Show code:
asked Jul 2, 2015 at 7:55
4
CSS
The final potential alternative using CSS would be to use
Javascript / jQueryAs such, there is no way in CSS to absolutely toggle a styled state- if none of the above work for you, you will either need to combine with a change in your HTML (e.g. based on a checkbox) or programatically apply/remove a class using e.g. jQuery
answered Jul 2, 2015 at 8:01
SW4SW4 68.3k20 gold badges128 silver badges134 bronze badges 2 We're going to to be using a hidden checkbox. -- To make content itself clickable: HTML
CSS
To make button change content: HTML
CSS
Hope it helps!!
isherwood 54k15 gold badges105 silver badges147 bronze badges answered Dec 8, 2017 at 19:23
In the Divi Theme Documentation, it says that the theme comes with access to 'ePanel' which also has an 'Integration' section. You should be able to add this code:
into the the box that says 'Add code to the head of your blog' under the 'Integration' tab, which should get the jQuery working. Then, you should be able to style your class to what ever you need. answered Jul 2, 2015 at 12:55
Not the answer you're looking for? Browse other questions tagged html css wordpress or ask your own question. |