The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
multiple selection custom profile field in postbit
i've been trying to add a multiple-selection profile field for "Sex" with the options, "boy", "girl" and "yes, please." to my postbit.
i know how to add a custom field to the postbit, but the multiple-selection thing is putting "1", "2" or "3" in the postbit instead of the actual option names. |
#2
|
||||
|
||||
Okay, what variable are you using right now for displaying the field which gives you 1, 2 or 3?
Also, exactly what type of profile field is the Sex one? |
#3
|
||||
|
||||
Code:
<b>Sex:</b> $post[field10] |
#4
|
||||
|
||||
You have to unserialize the field, etc. in order to get the proper answer. Maybe someone could help you out with this as I don't have the time to do this at the moment, although it shouldn't take too long to do for most coders
|
#5
|
||||
|
||||
If your using RC1 or 2:
Change your custom user profile field to: "Yes, including a first blank option" ALSO make sure it's editable by the user. Then in your postbit (or Postbit legacy) put the code: PHP Code:
Change all the "field99" to the number of the profile field. For example if it's 'Biography' it would be profile "field1". And that should work for you. |
#6
|
||||
|
||||
Quote:
|
#7
|
||||
|
||||
anyone? :nervous:
|
#8
|
||||
|
||||
use
<if condition="$userinfo[field99]==1">$vbphrase[boy]</if> <if condition="$userinfo[field99]==2">$vbphrase[girl]</if> <if condition="$userinfo[field99]==3">$vbphrase[yes_please]</if> |
#9
|
||||
|
||||
Quote:
|
#10
|
||||
|
||||
sorry, it should be $bbuserinfo not $post
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|