vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Profile Enhancements - [Sog-team]xFire Custom Profile Block (https://vborg.vbsupport.ru/showthread.php?t=184325)

m002.p 07-02-2008 10:00 PM

[Sog-team]xFire Custom Profile Block
 
What is it?

This mod will allow you to have an extra "module" on user profile pages which will display a xfire status block with a miniprofile link and option to add the user to your contacts list.

Demo?


http://www.sog-team.co.uk/forum/member.php?u=539

See right hand side of profile page.

Installation Instructions:

1)
First add a new profile field if not already present, where the user can add their xfire user id.
Code:


"Admin CP > User Profile Fields > Add new user profile field"

Use the following options:

Code:

Single line text box

Title: Xfire User ID
Field Editable by User > Yes

Save

2)
Now add another profile field again if not already done so previously. This will be the style options.

Code:

Single Line Selection Menu

Title: xFire Profile Style
Options: sh, co, sf, os, wow, bg (Separate by carriage return)
Field Editable by User > Yes

Save

3)
Upload the attached image to forum/images

4)
Upload the attached product xml

5)
Now edit template "memberinfo_block_xfire" for the relevant styles

For all instances of $userinfo[fieldxx], replace "xx" with the number of the field ID for your xfire user ID entry field created.

For the one instance of $userinfo[field00], replace "00" with the field ID of your xfire style selection profile field (the second one we created in this tutorial)

Save the template.

6) COMPLETE

-------------------------------------------------------------------------------------------------------------------

Display Options

Now although it seems as if this mod may only be displayed on the right hand side as shown in the demo, you may actually change its order or have it displayed in a new tab on the left if required (as there can be some problems with the image sizing when as a block on the right)

All you have to do is this.

1)
Go
Code:

Admin CP > Products & Plugins > Plugin Manager > Xfire Profile Hack
2)
Edit the plugin, ensure it is set as a product for "vbulletin", then edit the PHP code to find:
Code:

'hook_location' => 'profile_right_mini'
3)
Now change "profile_right_mini" with any of the following explained options:

Code:

'profile_left_first' (Will be displayed first in front of "Visitor Messages")
'profile_left_last' (Will be located last in the tabs after "Contact Info")
'profile_right_first' (Will be located first / top on the right)
'profile_right_mini' (Will be located after the mini stats block)
'profile_right_album' (Will be located after the albums block)
'profile_right_last' (Last block on right hand side)

4) Done

--------------------------------------------------------------------------------------------------------------------
UPGRADE:

Please just import the new product XML, and ensure you click "overwrite" to YES!

-------------------------------------------------------------------------------------------------------------------
Please INSTALL this modification should you use it for notification of the future releases!

Planned Future Updates:

Alternate TAB template for users wanting to display as a tab
Intergrated vbulletin admincp options
BB Code addition for users to distribute their sig

Version Tracker:

Version 1.0: Initial Release
Version 1.1: Fixed Product XML

NGUYENDUCTRUONG 07-03-2008 10:15 PM

Thank you for the update :D

Jeordie015 07-03-2008 11:58 PM

Shouldn't the style options be a single selection menu?

Also, you might want to resize the image you attached since we have to resize it using code to fit in the block. The image gets distorted when you do that.

Edit again: Actually, both images have to be resized via code, distorting them.

Edit 3: It still shows the block in the profile if you don't put anything in the profile field.

Q-v-n-s-Q 07-04-2008 04:05 AM

seem like a lots of the similiar mod out there

m002.p 07-04-2008 04:49 AM

Quote:

Originally Posted by Jeordie015 (Post 1566307)
Shouldn't the style options be a single selection menu?

Also, you might want to resize the image you attached since we have to resize it using code to fit in the block. The image gets distorted when you do that.

Edit again: Actually, both images have to be resized via code, distorting them.

Edit 3: It still shows the block in the profile if you don't put anything in the profile field.

Correct. Sorry last night I was tired and probably should have released this mod today.

Basically both images have to be resized if used as a module on the right hand side. I will attach a better xfire logo later, but regarding the actual miniprofile, there is little possible to do bar manually adjust its size like ive done in the template SRC.

However, you are not restricted to use this mod only in the right hand side. You may use it in various locations, even as a new tab next to "Visitor Messages", "Friends", "About Me" etc should you wish.

Simply edit the member_info_xfire template and remove the
Code:

width="230" height="63"
from the miniprofile SRC.

Now go
Code:

ADMIN CP > Plugin Manager > xFire Profile Hack
Ensure the product is "vbulletin" for starters, and secondly in the PHP code find:
Code:

'hook_location' => 'profile_right_mini'
You may adjust the "profile_right_mini" to any of the following parameters:

'profile_left_first' (Will be displayed first in front of "Visitor Messages")
'profile_left_last' (Will be located last in the tabs after "Contact Info")
'profile_right_first' (Will be located first / top on the right)
'profile_right_mini' (Will be located after the mini stats block)
'profile_right_album' (Will be located after the albums block)
'profile_right_last' (Last block on right hand side)

Hope that helps, and sorry about the problems experienced. Ive updated the mod as above.

Matt

michael5472 10-11-2008 06:58 AM

This doesn't show for me :( see attachment

m002.p 10-13-2008 06:05 PM

What is your vb version, contents of the relevant template and plugin?

XxSparks 10-15-2008 04:14 AM

My version of vBulletin is actually 3.7.3 and im having the same problem as michael. I have a good knowledge base of vBulletin and Skins and I've tried moving a couple things around, yet still. It's not working.

What do you think might be the problem?

m002.p 10-20-2008 09:57 PM

plugin code. I need the contents of your current plugin for this hack please.

Thanks

Replicators 10-25-2008 09:17 PM

Mine works, but it realy screws up everything, view screenshot to see.

memberinfo_block_xfire
Code:

$stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<if condition="$userinfo[field6]">
<div class="alt1 block_row">
    <ul class="list_no_decoration">
<thead>
<table>
<td align="center" class="alt2"><font size="1"><img src="images/xfire_logo.jpg" alt="Xfire - Gaming Simplified">xFire User Account: <b>$userinfo[field6]</b></font>
</td>
</table>
<br />
</thead>

<center>
<a href="http://profile.xfire.com/$userinfo[field6]" target="_blank"><img src="http://miniprofile.xfire.com/bg/$userinfo[field7]/type/1/$userinfo[field6].png" border="0"/></a>
</center>

<br />
<center><font size="1"><a href="xfire:add_friend?user=$userinfo[field6]" rel="nofollow"><b>Add $userinfo[username] to xFire Contacts List</b></font></center>
    </ul>
</div>
</if></html>

Another thing, you need to remove the <img src="/forum/images/xfire_logo.jpg" and rename it to <img src="images/xfire_logo.jpg" instead >8P Something is definantly wrong though, and i am assuming it's because i do not allow html, and it has html tags there. Anyway you can make this mod work without the use of html?
EDIT1: Ok monkeying around with the template, you need to remove thead, that messes up the placement, now i just need to figure out how to remove the linking of the vbulletin version and everything.


All times are GMT. The time now is 10:03 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01132 seconds
  • Memory Usage 1,752KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (10)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete