[wp-hackers] Saving Radio Options in Plugin Menu

Otto otto at ottodestruct.com
Sat Nov 23 12:06:55 UTC 2013


On Sat, Nov 23, 2013 at 5:51 AM, BenderisGreat <greglancaster71 at gmail.com>wrote:

> Hmm, I actually asked for help here:
>
>
> http://stackoverflow.com/questions/18675307/checkbox-wont-stay-checked-on-plugin-settings-page
>
> and that was the top upvoted answer so I tried it and it did save the
> result.  It stored 'on' in the array.
>
> Thank you for clarifying it was wrong. :-/
>
>
Actually, the answer there is mostly correct. He has the duplicated ID
problem, but by using the numbered printf placeholders to duplicate the
first parameter in the printf, he has the values set correctly. Also, he
uses the checked() method correctly, with the false third parameter.

-Otto


More information about the wp-hackers mailing list