Checkbox Problem or my HTML?

Hi guys I.ve been debugging this for almost an hour. The problem is when checking the button it does not stay in active and wont stay on the checkbox Image provided of desired solution. Active state + checkbox https://codepen.io/pen?template=XWPyZMm
CodePen
...
5 Replies
glutonium
glutonium2y ago
explain a bit more pls I've seen the codepen the checkbox seems to be working fine
Jochem
Jochem2y ago
you've got a couple of issues: 1) Buttons should not contain other interactive content like checkboxes 2) The buttons are submitting the form, which is causing the page to refresh and thereby resetting its state the checkboxes only work properly if you click the checkbox itself, the issue happens when you click the label / rest of the button
glutonium
glutonium2y ago
it redirects to somewhere i think
Jochem
Jochem2y ago
it's submitting the form to the current page, which doesn't work on codepen
glutonium
glutonium2y ago
hmmmm okee gotcha tnx
Want results from more Discord servers?
Add your server