Support Forum

Profile Custom Fields – list not showing

AB audrey boss
audrey boss
Member

Hi,

 

I am creating some custom profile fields for my forum members and it’s all working fine apart from the ‘list’ function. When i try to create a custom field which is a list (i.e. m,embers have a multiple select choice), it automatically changes to ‘select’ when i save it. What am i doing wrong?

Also, can you point me in the right direction for the appropriate plugin to display the custom fields in the profiles online for other members so i can send it to my developer and he can set it up.

thanks,

Audrey

7 Answers

New Answer

MP Mr Papa
Mr Papa
Member

how are you creating a custom list? with the custom profile fields plugin? 

if so, that plugin can display them… have you seen:  http://codex.simple-press.com/codex/plugins/our-plugins/available-plugins/custom-profile-fields/

if not, where is this custom list stored?  in wp usermeta? 

YS Yellow Swordfish
Yellow Swordfish
Member

I am sorry. I answered this post yesterday but i think I forgot to hit the ‘submit reply’ button!

The issue with the field type switching to ‘select’ I was able to replicate and I have fixed the problem. This will be in the next update due very, very soon. We only need WordPress 3.6 to be released and that is currently in it’s third beta outing. So wont have to wait long we hope.

AB audrey boss
audrey boss
Member

Ok thanks, so effectively I cannot add this feature until the new realease comes out?

MP Mr Papa
Mr Papa
Member

That is correct…

Andy made the change to the plugin, so will let him weigh in on whether the code change was small enough to post here and for you to make the same change yourself on your code base…

YS Yellow Swordfish
Yellow Swordfish
Member

Sure. It is a fairly small and minor code change if you want to make it yourself…

The file (in the custom profile field plugin is /admin/sp-custom-profile-fields-admin.php

Down around line 56 in that code file you will find these 2 lines of code:

echo '<option value="select"'.$sselected.'>'.__('Select', 'cpf').'</option>';
echo '<option value="select"'.$lselected.'>'.__('List', 'cpf').'</option>';

That second line SHOULD read:

echo '<option value="select"'.$sselected.'>'.__('Select', 'cpf').'</option>';
echo '<option value="list"'.$lselected.'>'.__('List', 'cpf').'</option>';

and that’s it.