I have a custom Checkbox its made in a Div
<div class="zs" name="toggle" state="on" id="zs"></div>
The checkbox has toggle on/off and the state attribute changes on click to on/off.
The div is placed in a for submittion but I dont know how to get $_POST['toggle'] from php to receive the attribute "state"
nameattribute doesn't make adiva form element... You'll have to either build the POST with javascript (in which case we want to see that code), or use a plain old checkbox (remember you can have a big label for that checkbox, so formatting-wise there are a lot of options).divfor this. Really, alabelwith aforattribute and a hidden<input type="checkbox">seems the way to go here if you don't want to manually build the post. Or update an<input type="hidden">somewhere.