Log in

View Full Version : How do I show a custom profile field


flyrib
05-06-2012, 07:49 PM
Hello, How do I get custom profile field to show up under the username when they post?

I've just added a new mandatory profile field that members have to fill in. But how can I make this field is always visible in posts, showing under their username?

thank you in advance :up:

kh99
05-06-2012, 07:58 PM
There's an article on how to do this: https://vborg.vbsupport.ru/showthread.php?t=250418 . (It's a vb4 article but I believe it will still work if you use vb3 template syntax).

The short answer is that if your profile field is text or single selection (menu or radio button), then you just need to put $post[fieldX] in your postbit or postbit_legacy template.

JacquiiDesigns
05-06-2012, 10:15 PM
Hmmm - I don't think vB 4.x syntax will work with vB 3.x
The following code may be of help though:

<if condition="$post['fieldX']"> <strong>Field Name:</strong> $post[fieldX]</if>
where "X" is the number of your new custom field.

HTH ;)

J.

kh99
05-06-2012, 10:43 PM
Hmmm - I don't think vB 4.x syntax will work with vB 3.x


You're right, that's why I mentioned that you'd need to use vb3 template syntax. I wanted to point out the article anyway because if you want to use a multiple selection profile field it gets a little more complicated.

flyrib
05-07-2012, 04:40 AM
thank you for your answers, should be a lot of people that have done this with their forums right? Will try this code during the day.

JacquiiDesigns
05-07-2012, 04:45 AM
You're right, that's why I mentioned that you'd need to use vb3 template syntax. I wanted to point out the article anyway because if you want to use a multiple selection profile field it gets a little more complicated.

Ah okay...
Just as an FYI - here's a list vB 3.x template conditionals (http://tech6.com/f51/vbulletin-template-conditionals-list-t112/). I've bookmarked it and have used it as a resource dozens of times. Should be helpful ;)

J.

Xp.Warrior
05-10-2012, 01:08 AM
Use This Coding
<if condition="$post['fieldX']"> <strong>Field Name:</strong> $post[fieldX]</if>
And [fieldX] Clear X And write Your Field Number
And Use This Code In Your admincp --> Styles & Templates --> Search in Templates --> postbit_lagacy And Add This Coding Where You Want To Look
i Hope This Is Usefull For You

JacquiiDesigns
05-10-2012, 04:55 PM
Use This Coding
<if condition="$post['fieldX']"> <strong>Field Name:</strong> $post[fieldX]</if>
And [fieldX] Clear X And write Your Field Number
And Use This Code In Your admincp --> Styles & Templates --> Search in Templates --> postbit_lagacy And Add This Coding Where You Want To Look
i Hope This Is Usefull For You

Um- You copy/pasted part of my post as if it's new information how...?https://vborg.vbsupport.ru/

J.

Xp.Warrior
05-10-2012, 11:55 PM
Um- You copy/pasted part of my post as if it's new information how...?http://img821.imageshack.us/img821/1364/wildeyed.gif

J.

admincp --> Styles & Templates --> Search in Templates --> postbit_lagacy And Add This Coding This Is New Information

JacquiiDesigns
05-11-2012, 03:08 PM
oh. okay.
Thanks :)