Hi all.
I have a web page using websockets.
I have a maindiv and inside that I have buttons and a checkbox input.
The button show up in the maindiv_click subroutine but the input device does not and does not change on/off
I shall try and be more succinct.
I have rocker switches on a web page that I need to turn on OR off.
If I have these in a <div> with an id of maindiv which I use in code using a Sub MainDiv_click event the switch will not change state.
I assume the event is being captured by websockets. (No idea, I am but a trainee)
So my main want is to get a response in code for the id= "toggle-trigger". Then I may be able to turn lights on an off via MQTT.
I am using Bootstrap 3
I hope this might fill in some gaps in my question.
yours
Tom
Oops I must say I am sorry with the question.
It seems to be the use of a "checkbox" with a div that the program is checking. I do a Maindiv_click sub.
If this id is left blank then the checkbox does toggle, however, if this checkbox is within the <div id="maindiv"> then the toggle does not happen.