The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
How To Add Custom Profile Field Information To The Postbit
So you've added some custom profile fields and would like the information to display in the postbit, but how do you go about it? This guide will help you to do this. Throughout this guide the x in fieldx is to be replaced with the field number as shown in the profile field manager in the name column. Single Line Text Boxes To add the contents of a single line text box to the postbit, use one of the following formats: To use a title for the displayed text (eg Real name: Kerry-Anne) Code:
<if condition="$post[fieldx]"><div class="smallfont">Label for text: $post[fieldx]</div></if> Code:
$post[fieldx] While I don't recommend displaying these in the postbit as they can contain a large amount of information, they are done in the exact same way as the single line text box. Note: The text entered will display all on one line, not in multiple lines as added to the text box and displayed in the profile page. Single Selection Radio Buttons & Single Selection Menus These both display text in the same way as the Single Line Text Box so the same format can be applied to these. However, as these are mainly used for fixed options (eg Date of Birth, or Homepage contains adult content here at vB.org) they can also be used to display images (eg the gender in postbit modification). These examples, using images, assume that you have uploaded the images to your misc image directory for the style that you are using. You can replace Code:
$stylevar[imgdir_misc] Code:
.gif To use the contents to display an image, with no label, use the following format: Code:
<if condition="$post[fieldx]"><div><img src="$stylevar[imgdir_misc]/$post[fieldx].gif" border="0" alt="$post[fieldx]" /></div></if> Code:
<if condition="$post[fieldx]"><div class="smallfont">Label for image: <img src="$stylevar[imgdir_misc]/$post[fieldx].gif" border="0" alt="$post[fieldx]" /></div></if> I wouldn't recommend using these to display information in the postbit, as to enable them requires long usage of conditionals to translate the code saved in the database into displayable text. I hope you find this useful. Feel free to ask any questions related to this. |
#32
|
|||
|
|||
exactly what I need! ty
|
#33
|
|||
|
|||
How can I choose an image and have it link to the url in the profile field. Like if I wanted to put a lil facebook image and have it go to their profile field "facebook profile"
|
#34
|
|||
|
|||
the site I am working on currently has something like 4000 members. I want to add a new profile field and it have a default of 0. Is there some kind of query that I need to run to have every member's profile field have a default answer of zero? If so how do I do this?
|
#35
|
|||
|
|||
Hmmm, I'm a bit lost, I'm sure it's just me but I can't see where I actually place this code?
Do I need to also give it positional information as well? What I'm trying to do is this :https://vborg.vbsupport.ru/showthrea...83#post1804983 Naturally, I'm a noob to Vbulletin customisation |
#36
|
|||
|
|||
Thank you! This was so quick and simple. It took about 2 minutes to do.
|
#37
|
||||
|
||||
Quote:
--------------- Added [DATE]1246771254[/DATE] at [TIME]1246771254[/TIME] --------------- Ahh mkay I got it.. Using: PHP Code:
|
#38
|
|||
|
|||
Ok this may sound like a dumb question but where am i supposed to put this code to make it show in the postbit? I tried putting it in the regular expression area and nothing came up on the postbit. I am running the newest version of vbulletin 4.1.5
|
#39
|
|||
|
|||
I'm guessing this doesn't work for vB4. My html code is being displayed literally on the page and not parsing.
Edit: Here's a guide. https://www.vbulletin.com/forum/show...tbit-templates |
#40
|
||||
|
||||
There is a different one for vB4 in the vB4 articles area (and in my profile since I was the one who wrote it).
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|