This is a pretty common form format:
(Imagine that the textbox was next to the word ‘Other’ – wpautop() or something is being a stupid craphead and inserting a line break.)
It’s not really possible with BuddyPress’s xprofile fields. Today I dove into the codebase to see how hard it would be to add such a feature natively. The answer: Too.
So I wrote a hackish plugin instead, which you can get from this gist. (Note that it’s not in a plugin wrapper. Put it in your bp-custom.php.) To use: (1) On the Admin screen for a profile field, select ‘Yes’ under “Other Field”. (Note: it only works for checkbox fields!!) (2) ??? (3) Profit.
??? = all the benefits that eventually lead to (3) Profit. Yes?
Thanks for this. I’ve wondered about this functionality…
Also, off the top of my head, I would have imagined that it would be most important for radio buttons, (which are exclusive as opposed to checkboxes, right?) since then if they choose “other” they definitely aren’t providing any info whatsoever.
Am I in left field on this one?
Daniel – Makes a lot of sense. What’s written here could be modified fairly easily to support radio buttons as well (I think you’d just need to change some of the type checks, and then build the markup appropriately). If I need it for a project, I’ll build it and post it here.
I wondered if it might be an easy mod.
I’ll let jetpack/wp.com (whichever you have) notify me of whatever’s to follow 🙂
Thanks,
Any chance this could be updated to work with current version? When I try this I get a 500 error.