Back to vBulletin 3.7 Template Modifications

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

This modification is in the archives.
vB Version: 3.7.6 Rating: (2 votes - 4.00 average) Installs: 10
Released: 26 Apr 2009 Last Update: Never Downloads: 31
Not Supported Template Edits Re-usable Code Translations  

UKBL ~ Twitter profile link on Postbit ~ Clickable !!


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

Not been on for a while but i've had numerous requests for this Twitter hack so here we go....

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

Runs along the same lines as the Facebook Hack, so if you've installed that, you'll love this




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 = Twitter User Name

Description = Enter Your Twitter username from your Twitter User Profile

Default Value = Leave empty

Max length of allowed user input = 20

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="https://twitter.com/$post[field11]">
<img alt="My Twitter" border="0" src="attach/images/misc/stub.png" border="0"/>
</if></if>
replace the RED Field attribute for your own and dont forget to replace the twitter image show in the above code for your own, see below

Code:
attach/images/misc/stub.png
I've added several twitter images below but feel free to use your own

They are in .gif and .png, use the ones you feel happiest with








Now when members sign up their Twitter badge and enter their profile user ID into the "Enter your twitter username from your Twitter 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 Twitter profile urls

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

Next, Upload the Twitter 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 Twitter

Please Click Installed and I'll support you 100%

Thanks

Download

This modification is archived, downloads are still allowed.

File Type: %1$s twitter to postbit.zip (36.1 KB, 34 downloads)

Screenshots

Click image for larger version
Name:	twit1.gif
Views:	12
Size:	10.9 KB
ID:	98379   Click image for larger version
Name:	twit2.gif
Views:	12
Size:	7.2 KB
ID:	98380   Click image for larger version
Name:	twit3.png
Views:	11
Size:	5.0 KB
ID:	98381   Click image for larger version
Name:	twit4.png
Views:	14
Size:	6.1 KB
ID:	98382  

Click image for larger version
Name:	twit5.png
Views:	11
Size:	7.4 KB
ID:	98383   Click image for larger version
Name:	twit6.gif
Views:	13
Size:	1.7 KB
ID:	98384   Click image for larger version
Name:	twit7.gif
Views:	13
Size:	2.7 KB
ID:	98385  

Similar Mods

Forum Home Enhancements UKBL ~ FaceBook profile link on Postbit vBulletin 3.8 Template Modifications
Profile Enhancements Twitter Profile 1.0 (displays Twitter on a member's profile page) vBulletin 3.7 Add-ons
End-User Options UKBL ~ Twitter profile link on Postbit ~ Clickable vBulletin 3.8 Template Modifications
End-User Options UKBL ~ Selling on Ebay Link in Postbit vBulletin 3.8 Template Modifications
Forum Home Enhancements UKBL ~ FaceBook profile link on Postbit ~ Clickable vBulletin 3.7 Template Modifications

vblts.ru supports vBulletin®, 2022-2024