We are about to switch to a new forum software. Until then we have removed the registration on this forum.
I've used createRadio() in my setup() to create a series of radio buttons with three options. Can I specify one of the radio buttons being checked by default? Is this something I can do in the js or in the html?
You can do it in your setup().
radio = createRadio();
radio._getInputChildrenArray().checked = true;
You are supposed to be able to pass a parameter to the .value() function to set a given radio button as checked too (according to the p5.js source, at least), but I couldn't get it to work!
Like, this should work:
This is nuts, but I have the exact opposite results from you. Your setup() example doesn't work for me, but passing a parameter into the .value() does work. Wha...?
Regardless, you have solved my issue. TY TY TY.
To be fair, I was just trying it using the EDIT button on this page:
But since you got it working, no worries!