Toggle html type radio

I don't know where I'm going wrong in this template, it doesn't return any value in msg.payload.
What am I doing wrong?

[{"id":"bccb9899b9a343de","type":"ui_template","z":"64552269fb569901","group":"14a863b7b2e5e91a","name":"","order":0,"width":0,"height":0,"format":"<form>\n    <input type=\"radio\" id=\"1\" name=\"switch\" value=\"1\">\n    <label for=\"1\" style=\"background-color: blue;\">TCP/IP</label>\n    <input type=\"radio\" id=\"0\" name=\"switch\" value=\"0\">\n    <label for=\"0\" style=\"background-color: red;\">Serial</label>\n    <button type=\"submit\">Enviar</button>\n</form>\n\n<script>\n  this.scope.action = function(value) { return value; }\n</script>\n","storeOutMessages":true,"fwdInMessages":true,"resendOnRefresh":true,"templateScope":"local","className":"","x":1040,"y":1060,"wires":[["929b837394122ae9","e03f65e06876bf81"]]},{"id":"e03f65e06876bf81","type":"debug","z":"64552269fb569901","name":"debug 10","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1300,"y":1120,"wires":[]},{"id":"14a863b7b2e5e91a","type":"ui_group","name":"Default","tab":"0be9643108e709d3","order":2,"disp":true,"width":"6","collapse":false,"className":""},{"id":"0be9643108e709d3","type":"ui_tab","name":"Tabela","icon":"dashboard","order":1,"disabled":false,"hidden":false}]

Did you take a look at the 'Sending a Message` example in the Help?
Screenshot 2023-02-12 at 11.08.14 AM

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.