Back to vBulletin 3.8 Template Modifications

UKBL ~ FaceBook profile link on Postbit
Mod Version: 1.00, by UKBusinessLive

vB Version: 3.8.1 Rating: (18 votes - 4.67 average) Installs: 112
Released: 13 Mar 2009 Last Update: Never Downloads: 360
Not Supported Template Edits Re-usable Code Translations  

UKBL ~ FaceBook profile link on Postbit ~ Clickable !!


Member on Facebook? Show other members that you have a Facebook presance by adding a facebook Icon to your postbit"

This is a cool hack which will let your members add a facebook Icon to their Postbit template, They need to add their facebook Profile user ID in their user CPfor this to show, If they don't enter one, then the badge don't show



How to install.

Its really easy to do, as always, so if your sitting comfortably, lets begin

Now we need to create a User Custome field, so.....

AdminCP and add a custom field > User Profile fields > Add New User Profile Field

Title = Facebook user ID

Description = Enter the Number ID from your Facebook User Profile

Default Value = Leave empty

Max length of allowed user input = 12

Display Size = 10

Display Order = 10 or 15

Field Required = No as default

Field Editable by User = Yes in case member wants to delete, Later

Private Field = No

Field Searchable on Members List = No

Show on Members List = Yes

Regular Expression = leave empty

Save the field

Once you've saved you can see what the field number is, So lets say its Field11 for example, Remember this as will need it for your Postbit Edits

Thats the first bit done, now Part Two

Go to the template you are using in Styles & Templates/Style Manager, and select Edit templates.

Go to "postbit templates" and select the template you are using, either postbit or postbit_legacy.

Find the following

Code:
<if condition="$post['joindate']"><div class="postbit">$vbphrase[join_date]: $post[joindate]</div></if>
Directly above it add

Code:
<if condition="is_member_of($bbuserinfo, 6, 7, 9)">
<if condition="$post['field11']">
<a href="http://www.facebook.com/home.php/#/profile.php?id=$post[field11]&ref=profile">
<img alt="My Facebook" border="0" src="http://www.yourforum.com/images/misc/facebook.png" border="0"/>
</if></if>
replace the RED Field attribute for your own

now when members sign up their facebook badge and enter their profile user ID into the "Enter the Number ID from your Facebook User Profile" section in their UserCP, The Badge will automatically appear in their Postbit

Don't forget to change the usergroup condition with the number of the usergroups that you want to be able to view this

Code:
<if condition="is_member_of($bbuserinfo, 6, 7, 9)">
That means that guests and banned users will not be able to view members facebook profile urls

Members who do not add a user id will not be shown anything.

Next, Upload the facebook icon to your forums/images/misc folder and add the full url to the part in the code which shows the image.

if you are just seeing a red cross on your postbit, then its because your image url is not right

Oh Forgot to say, Badge is fully clickable so members can click directly to facebook

Hope you enjoyed this new hack, and thanks to DobieGillis© for the idea

Please Click Installed and I'll support you 100%

Thanks

Download

File Type: %1$s facebook.zip (110.5 KB, 438 downloads)

Screenshots

Click image for larger version
Name:	facebook1.png
Views:	475
Size:	79.1 KB
ID:	96339   Click image for larger version
Name:	fackbook2.png
Views:	434
Size:	35.3 KB
ID:	96340  

Similar Mods

Mini Mods MySpace & FaceBook buttons in member profile and postbit vBulletin 3.6 Template Modifications
End-User Options UKBL ~ Selling on Ebay Link in Postbit vBulletin 3.8 Template Modifications
End-User Options UKBL ~ Selling on Ebay Link in Postbit vBulletin 3.7 Template Modifications
End-User Options UKBL ~ Selling on Ebay Link in Postbit vBulletin 3.6 Template Modifications

vblts.ru supports vBulletin®, 2022-2024