Tagged: echo xprofile fields
hi, i am trying to echo a xprofile field tha is a Multi select box. i am using one of your solutions givenin here: https://buddydev.com/fetching-and-showing-only-specific-fields-from-buddypress-xprofile-data/#comment-3439
‘echo bp_unserialize_profile_field( xprofile_get_field_data( ‘CheckboxFieldName’, get_the_author_id()) ) );’
the only result i get is “Array”. the ocde works fine when normal fields are echoed.
I hope you can find time to help me.
Best,
HanHi Han,
You can use this insteadxprofile_get_field_data( 'CheckboxFieldName', get_the_author_id(), 'comma' );
Also, there is no need to use bp_unserialize_profile_field(). BuddyPress does that automatically for you when you use xprofile_get_field_data.
Please let me know if it works for you or not?
Regards
Brajesh
The topic ‘ [Resolved] echo Multi select boxes -> array’ is closed to new replies.