PDA

View Full Version : Add XFire URLS to User Profile Info


murdo
18 Sep 2006, 10:23
Only my second released mod, tested and working with vBulletin 3.6.0, 3.6.1. and 3.6.2

Thanks to +buG (http://www.vbulletin.org/forum/member.php?u=14810) and Ev!L ErN!E (http://www.vbulletin.org/forum/member.php?u=130960) for their input / suggestions.

This template mod will allow you to add your users Xfire ID as a link, on their forum posts. This link, when clicked on, will add that user to his/her Friends list!


http://www.nc-ownage.co.uk/image1.jpg


Admin CP -> User Profile Fields -> Add New User Profile Field

Choose "Single Line Text Box"

Title: XFire Username
Display Order: (you choose!)
Field Required: (you choose!)
Field Editable by User: (you choose!)
Private Field: NO
Field Searchable on Members List: Yes
Show on Members List: (you choose!)
Display Page: Edit Profile

[SAVE]


NOTE:
You must now make a note of the field ID for your Xfire input. You can check what field ID is assigned by going to:

Admin CP -> User Profile Fields -> User Profile Field Manager

and looking at what ID is next to "XFire Username"

For my instructions, i am going to use '99' as my Field ID, and you should change the number to suit what YOUR field ID is!

INSTRUCTIONS FOR ADDING XFIRE ID AS TEXT LINK:

Go to AdminCP
Go to "Style Manager"
Go to "Edit Templates" for your theme.
Scroll down until you get to "Postbit Templates"
Open up either Postbit or Postbit Legacy (depending on what you use!)

Find in this template:

<if condition="$post['field2']"><div>$vbphrase[location_perm]: $post[field2]</div></if>

and below it, add:

<if condition="$post['field99']"><div>XFire: <a href="xfire:add_friend?user=$post[field99]">$post[field99]</a></div></if>

Save.

REMEMBER!! CHANGE THE ['field99'] AND [field99] to whatever field ID you have, i.e ['field6'] / [field6] or ['field9'] / [field9] !!


INSTRUCTIONS FOR ADDING XFIRE ID LINK AS AN IMAGE:

Go to AdminCP
Go to "Style Manager"
Go to "Edit Templates" for your theme.
Scroll down until you get to "Postbit Templates"
Open up either Postbit or Postbit Legacy (depending on what you use!)

Find in this template:

<if condition="$post['field2']"><div>$vbphrase[location_perm]: $post[field2]</div></if>

and below it, add:

<if condition="$post['field99']"><div><a href="xfire:add_friend?user=$post[field99]"><img src="putyourimagehere.gif" border="0"></a></div></if>

Save.

REMEMBER!! CHANGE THE ['field99'] AND [field99] to whatever field ID you have, i.e ['field6'] / [field6] or ['field9'] / [field9] !!

Snake
18 Sep 2006, 12:28
Thanks. Works like a charm! ;)

oberheimhaven
18 Sep 2006, 19:12
Great Hack
Thxs
MarkAnthony

murdo
18 Sep 2006, 21:35
Your very welcome guys. Sorry if my instructions were a bit poor, its my first public release.. any tips would be appreciated! :)

Snake.. did you "Install It"? hint hint! lol :)

darkie79
20 Sep 2006, 08:09
Regretably, not working for me :(

murdo
20 Sep 2006, 09:53
darkie79, PM me with ur MSN / xfire ID and I will assist you. :)

+buG
20 Sep 2006, 17:38
Field99 should reflect the actual field# instead of the display order, shouldn't it?

murdo
21 Sep 2006, 09:01
yes. that is correct. I have just noticed my mistake in the instructions, and appologise!!!

Whatever "Display Order" you chose when u add a "User Profile Field", makes NO diference!!

Instructions on install have been amended accordingly.

Thanks you +buG for pointing that out!

murdo
21 Sep 2006, 10:26
Did you get it working bug?

darkie79
21 Sep 2006, 11:13
this worked for me, thanks all :)

dougeetx
21 Sep 2006, 18:51
Maybe a stupid question but what is Xfire???

iran.gs
27 Sep 2006, 21:53
Maybe a stupid question but what is Xfire???


this may help u buddy
http://www.xfire.com/

Ev!L ErN!E
20 Oct 2006, 12:41
is there a way to include an image for xfire? instead of text?

murdo
20 Oct 2006, 13:31
I have updated the install instructions to accomodate for using an image instead of the persons xfire id.

Please refer to the part:

INSTRUCTIONS FOR ADDING XFIRE ID LINK AS AN IMAGE:

Ev!L ErN!E
22 Oct 2006, 22:12
I have updated the install instructions to accomodate for using an image instead of the persons xfire id.

Please refer to the part:

INSTRUCTIONS FOR ADDING XFIRE ID LINK AS AN IMAGE:

Works great, I just had to add the border="0" line to the code so the image wouldn't have a border around it:

<if condition="$post['field99']"><div><a href="xfire:add_friend?user=$post[field99]"><img src="putyourimagehere.gif" border="0"></a></div></if>

Also this would be great if it was placed next to the other messanger icons, or even added as a field for messanger profiles, like Yahoo, MSN and AIM, could you create this as a mod for that as well?

Also I'm using 3.6.2 and its working fine...

murdo
23 Oct 2006, 07:46
Thanks Ev!L ErN!E, updated the instructions.

As for the mod you talk about... you read my mind! I'm already working on it :)

The Itchy One
03 Nov 2006, 08:34
Installed :)

Demo of the mod can be viewed at http://lovepants.co.uk/forum/showthread.php?t=67

Here is my Xfire logo
http://lovepants.co.uk/forum/images/buttons/logo_xfire.gif

murdo
06 Nov 2006, 09:24
Thanks for that! Will shortly be releasing v1.1 of the mod, with instructions on how to add the xfire image / link to the other Messenger icons/links... :)

fruitattack
23 Apr 2007, 19:59
Yup, I'm definitely anticipating that mod...unless I can figure that out myself. Thanks a lot for the tut, going to install it now.

Paul Wall
03 May 2007, 22:34
uhm whats the field thing? how do i know what feild i have? sorry im not so good.

byon
04 May 2007, 02:28
uhm whats the field thing? how do i know what feild i have? sorry im not so good.

you can find out under AdminCP -> User Profile Fields

Paul Wall
04 May 2007, 04:17
for some reason its not showing the xfire usernames, it says exfire but nothing after

http://www.valhallagaming.net/showthread.php?t=1352