Create a Custom Profile Field and Add It To The Postbit

Shahrukh Khan

New Member
To create a new profile field -
  1. Login to your Admin CP
  2. Scroll down to User Profile Fields
  3. Click on Add New User Profile Field
  4. Fill out all information on the next page. Pay special attention to Field Required (yes or no) and the display page.
  5. Save (make a note of the # of the profile field, you're going to need it!)
Now we're going to add this profile field to the postbit or postbit legacy template (depending on which one you use). For the purposes of this tutorial, we'll use postbit legacy, since that's what I use

  1. Still in the Admin CP
  2. go to Styles & Templates
  3. Style Manager > Postbit Templates > postbit_legacy
Decide where you want this new profile field. In this tutorial, we'll place it below the join date. So, find:

Code:
<if condition="$post['joindate']"><div>$vbphrase[join_date]: $post[joindate]</div></if>

and add below:

Code:
<if condition="$post['fieldX']">
    $post[fieldX]
</if>


Replace the X with the # of the profile field that I told you to note
Now, you may also want to label that profile field. For example, gender, first name, etc.

if so, change the code as follows:

Code:
<if condition="$post['field[b]X[/b]']">
  [b]  Gender:[/b] $post[field[b]X[/b]]
</if>

Enjoy!
 
Thanks i have done it but i have install Sexual Orientation and i want that picture to show with this
can i do that??
 
Great, but how can we add a field to under the username? I want to allow my users to add a custom title for themselves, but keep the default ranks at the same time.

I want only my PAID/ subscribed members to be able to do this.

Can this be done using your edit, or is there some form of mod to allow me to do it?

Thanks
 
ok use this:
where it says == to add the group id number for this group.
<if condition="$show[usergroupid] == ">
<div>$post[fieldx]</div>
</if>

replace x with your profile field. Enjoy mate any problems post and I`ll help you out.
 
Back
Top