Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
GamerCards Block in Profile Sidebar and Postbit Details »»
GamerCards Block in Profile Sidebar and Postbit
Version: 3.1.1, by BaziCenter BaziCenter is offline
Developer Last Online: Jun 2017 Show Printable Version Email this Page

Category: Profile Enhancements - Version: 4.x.x Rating:
Released: 01-02-2010 Last Update: 12-19-2012 Installs: 742
Uses Plugins Auto-Templates
Re-useable Code Additional Files Translations  
No support by the author.

This hack is for vBulletin v4.x.x so it's NOT working with vB3.x.

-----------
vB3.8.x compatible version:
https://vborg.vbsupport.ru/showthread.php?t=250964
-----------


Info:
This hack will add a new block in your user profile sidebar which contains user GamerCards and GamerIDs.
Also GamerCards show up on the postbit too. (pop-up pages)

Features:
-Global enable/disable system.
-Ability to change the block location in profile sidebar.
-Can choose to show only GamerIDs and not GamerCards.
-Ability to disable certain platform(s).
-Can show GamerCards with relevant icons in the postbit.
-This mod currently support the following platforms:
  • XBOX Live Gamertag
  • PlayStation Network ID (both US & EU versions)
  • Wii Friend Code (wii doesn't have a gamercard)
  • XFIRE Username
  • Steam Community ID
  • Raptr.com (Added in v3.0)
Install:
1) Navigate to AdminCP -> Plugins & Products -> Manage Products -> [Add/Import Product] -> Import XML product.
2) Upload the "gamericons" folder to your forum_dir/images/misc folder.*
3) Upload the "gamercard.php" to your forum's root folder.
4) You should create a "Single-Line Text Box" User Profile Field for each platform (if you don't have). (Help!)
5) Enter the field ID of each platform in vB Options -> "GamerCards Block Options" settings.

* If you have a custom style, you have to copy the gamericons folder in the misc folder of each style!

Upgrade:
1) Navigate to AdminCP -> Plugins & Products -> Manage Products -> [Add/Import Product] -> Import XML product.
When you want to import the XML, set Allow Overwrite to 'Yes'.
2) Upload the "gamericons" folder to your forum_dir/images/misc folder.
3) Upload the "gamercard.php" to your forum's root folder.

Notes:
1) For showing the PSN GamerCard, users must do the following:
US: Login to us.playstation.com -> My Profile -> Portable ID -> Generate Portable ID.
EU: Login to eu.playstation.com -> My Account -> My Portable ID -> Generate Portable ID.

2) For showing the Steam GamerCard, users must do the following:
Login to steamcommunity.com -> Edit my Profile -> Copy the text from the "Custom URL" box into the Steam ID field.
* Steam GamerCard is not official and generates from steamcard.com and steamprofile.com.
Note: Steam postbit pop-up page now support real Steam ID which is: STEAM_X:X:XXXXX.

3) XFIRE mini profile & EU PSN images will be resized with mouse hover.

4) You can use these optional Regular Expressions (regex) for the fields:
  • XBOX Live Gamertag: ^([A-Za-z0-9 ]+)?$
  • PlayStation Network ID: ^([A-Za-z0-9-_]+)?$
  • Wii Friend Code: ^([0-9]{4}[- ][0-9]{4}[- ][0-9]{4}[- ][0-9]{4})?$
  • XFIRE Username: ^([a-z0-9]+)?$
  • Steam ID: ^([A-Za-z0-9-_]+)?$ (this regex is for Custom URL only)
  • Raptr.com ID: ^([A-Za-z0-9-_]+)?$
Versions:
v1.0 - Initial version (3rd January 2010)
v1.1 - Added feature: new sidebar on right location (4th January 2010)
v2.0 - GamerCards added to the postbit too! (6th January 2010)
v2.5 - Better pop-ups with more options, added EU psn version, minor fix (7th January 2010)
v2.6 - Added WOL display, fixed the EU PSN compatibility with right sidebar, minor bugs fixed (13th January 2010)
v2.6.1 - W3C Validation fixed, better code (14th January 2010)

v2.6.2 - Syntax error fixed (only gamercard.php changed) (18th January 2010)
v2.6.3 - Now compatible with vB4.0.4 (23rd June 2010)
v3.0 - Added Raptr.com support, Steam pop-up page updated, some codes changed (22nd September 2010)
v3.0.1 - xbox.com links updated (31st October 2010)
v3.0.2 - Steam pop-up links fixed (5th January 2011)
v3.1 - Added user psn portable id selection menu, CSS data moved in to the <head>, Steam pop-up links fixed (15th May 2011)

v3.1.1 - Xbox.com links were fixed, bug fixes (20th December 2012)

Q: Why there are two versions for download?
A: 'bc-gamercards-vb4-v3.0.2.zip' works only on vB4.0.7 and lower! (I do not support these vB versions anymore).
'bc-gamercards-vb4.1-v3.1.zip' works on vB4.1.x.


NOTE: If you want to upgrade to v3.1 you MUST uninstall your current product first and then install it again because of new added DB codes.


Please Mark As Installed if you use this modification.

By the way this is my first hack, so I hope you like it.

Download Now

File Type: zip bc-gamercards-vb4-v3.0.2.zip (23.6 KB, 597 views)
File Type: zip bc-gamercards-vb4.1-v3.1.1.zip (24.5 KB, 669 views)

Screenshots

File Type: png gamercards_1.png (70.1 KB, 0 views)
File Type: png gamercards_2.png (7.9 KB, 0 views)
File Type: jpg gamercards_3.jpg (48.3 KB, 0 views)
File Type: png gamercards_vbsettings.png (212.8 KB, 0 views)
File Type: png gamercards_4.png (133.0 KB, 0 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
3 благодарности(ей) от:
Anbieter, CoZmicShReddeR, HittingSmoke

Comments
  #252  
Old 09-23-2010, 03:50 PM
Canis Firebrand Canis Firebrand is offline
 
Join Date: Jun 2006
Location: Michigan
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great mod and I love the way it looks in the member profile screen.

One wish item from me.

Currently, you have a single on/off option to turn off the gamer cards from being shown or not.
Would it be terribly hard to have a toggle option for each one?

On my board, some people have a PSN id listed but didn't do the portable gamer card thing. Therefore, they see a blank image in their profile. I want the XBox gamer card, etc to show.
So, what I had to do was modify the code to comment out the PSN portable gamer card section so it doesn't load at all.
Reply With Quote
  #253  
Old 10-23-2010, 09:01 PM
PreciseDemise PreciseDemise is offline
 
Join Date: Jun 2010
Location: England
Posts: 63
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Microsoft seem to have been bastards and switched up all the URL's to Add Friends etc to JavaScript.b As a result, this "http://live.xbox.com/en-US/profile/FriendsMgmt.aspx?gt=blueice26&act=Add" has become buried in here somewhere:
Code:
<script type="text/javascript" language="javascript">
//<![CDATA[
    function FriendCenterObject() {
        var fcAction = function(actionUrl, gamerTag, responseHandler) {
            responseHandler = responseHandler || function(response) {
                if (response.status != 0) {
                    DisplayMessageDialog('Error', response.view, 'Close', null, MessageLevelType.Error);
                }
                else {
                    DisplayMessageDialog('Message', response.view, 'Close', FriendCenter.RefreshContentAction);
                }
            }

            $.post(actionUrl, { 'gamerTag': gamerTag }, responseHandler);
        };

        this.AcceptFriendRequest = function(gamerTag) {
            fcAction('/en-GB/FriendCenter/AcceptFriendRequest', gamerTag);
            return false;
        };

        this.DeclineFriendRequest = function(gamerTag) {
            DisplayConfirmationDialog(
                'Decline Friend Request',
                'Are you sure you want to decline the friend request?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/DeclineFriendRequest', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };

        this.CancelFriendRequest = function(gamerTag) {
            DisplayConfirmationDialog(
                'Cancel Pending Request',
                'Are you sure you want to cancel your pending friend request?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/CancelFriendRequest', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };

        this.AddFriend = function(gamerTag) {
            gamerTag = $.trim(gamerTag); // trim leading and trailing whitespaces
            if (gamerTag != "") {
                fcAction('/en-GB/FriendCenter/SendFriendRequest', gamerTag);
            }
            return false;
        };

        this.RemoveFriend = function(gamerTag) {
            DisplayConfirmationDialog(
                'Remove',
                'Are you sure you want to remove this player from your friends list?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/RemoveFriend', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };

        this.BlockFriend = function(gamerTag) {
            DisplayConfirmationDialog(
                'Block User',
                'Are you sure you want to block this player from all further communications?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/BlockFriend', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };
        
        this.RefreshContentAction = function(){};
    };
    var FriendCenter = new FriendCenterObject();
//]]></script>
Which means all the hard coded stuff is no worthless as it leads to an "Oops" page. Any chance of a fix or is is just a case of stripping all the fat from the pop-up?
Reply With Quote
  #254  
Old 10-24-2010, 12:54 AM
Devil_Dog Devil_Dog is offline
 
Join Date: Jan 2010
Posts: 42
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by PreciseDemise View Post
Microsoft seem to have been bastards and switched up all the URL's to Add Friends etc to JavaScript.b As a result, this "http://live.xbox.com/en-US/profile/FriendsMgmt.aspx?gt=blueice26&act=Add" has become buried in here somewhere:
Code:
<script type="text/javascript" language="javascript">
//<![CDATA[
    function FriendCenterObject() {
        var fcAction = function(actionUrl, gamerTag, responseHandler) {
            responseHandler = responseHandler || function(response) {
                if (response.status != 0) {
                    DisplayMessageDialog('Error', response.view, 'Close', null, MessageLevelType.Error);
                }
                else {
                    DisplayMessageDialog('Message', response.view, 'Close', FriendCenter.RefreshContentAction);
                }
            }

            $.post(actionUrl, { 'gamerTag': gamerTag }, responseHandler);
        };

        this.AcceptFriendRequest = function(gamerTag) {
            fcAction('/en-GB/FriendCenter/AcceptFriendRequest', gamerTag);
            return false;
        };

        this.DeclineFriendRequest = function(gamerTag) {
            DisplayConfirmationDialog(
                'Decline Friend Request',
                'Are you sure you want to decline the friend request?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/DeclineFriendRequest', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };

        this.CancelFriendRequest = function(gamerTag) {
            DisplayConfirmationDialog(
                'Cancel Pending Request',
                'Are you sure you want to cancel your pending friend request?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/CancelFriendRequest', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };

        this.AddFriend = function(gamerTag) {
            gamerTag = $.trim(gamerTag); // trim leading and trailing whitespaces
            if (gamerTag != "") {
                fcAction('/en-GB/FriendCenter/SendFriendRequest', gamerTag);
            }
            return false;
        };

        this.RemoveFriend = function(gamerTag) {
            DisplayConfirmationDialog(
                'Remove',
                'Are you sure you want to remove this player from your friends list?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/RemoveFriend', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };

        this.BlockFriend = function(gamerTag) {
            DisplayConfirmationDialog(
                'Block User',
                'Are you sure you want to block this player from all further communications?',
                'Yes',
                'No',
                function() {
                    fcAction('/en-GB/FriendCenter/BlockFriend', gamerTag);
                }, null, '', MessageLevelType.Warning);
            return false;
        };
        
        this.RefreshContentAction = function(){};
    };
    var FriendCenter = new FriendCenterObject();
//]]></script>
Which means all the hard coded stuff is no worthless as it leads to an "Oops" page. Any chance of a fix or is is just a case of stripping all the fat from the pop-up?
Same issue with Xfire
Reply With Quote
  #255  
Old 10-24-2010, 12:10 PM
GeometriX_ZA GeometriX_ZA is offline
 
Join Date: Oct 2010
Posts: 2
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great mod! I have one little issue with it though. On my forums, I have users from both the US and EU PSN. I have a user profile field where they can choose their region, but I've been struggling to tie the option into your mod, as the global option results in either US or EU users to have broken popups. Can you recommend a solution?
Reply With Quote
  #256  
Old 10-30-2010, 07:52 PM
tele955848 tele955848 is offline
 
Join Date: Nov 2008
Posts: 110
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Wird nicht Angezeigt was mache ich falsch ?
Reply With Quote
  #257  
Old 11-25-2010, 05:43 AM
8thos's Avatar
8thos 8thos is offline
 
Join Date: Aug 2010
Location: Pensacola, FL
Posts: 772
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have vb4.08. Gamercards no longer show up on the right sidebar of Profile. I switched it back over to the left.
Reply With Quote
  #258  
Old 11-25-2010, 05:02 PM
BaziCenter's Avatar
BaziCenter BaziCenter is offline
 
Join Date: Sep 2005
Location: Montreal, QC
Posts: 85
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry but I don't have active license right now to check v4.0.8.
Reply With Quote
  #259  
Old 11-25-2010, 05:08 PM
Gleedo Gleedo is offline
 
Join Date: Oct 2008
Posts: 157
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well i have tried and tried but I cant get this to work lol - i know im being thick but i can't figure it out for steam...

I set my steam id to 5 which is the custom field (id) i created and saved the mod settings.

I then goto edit my profile and find the relevant field.

Now, what exactly goes in that field (an actual working string to enter would be good so I can see if the forum is showing it correctly before I try adding mine)
Reply With Quote
  #260  
Old 12-04-2010, 05:14 PM
ShawnV's Avatar
ShawnV ShawnV is offline
 
Join Date: Mar 2005
Posts: 270
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Anyone else having problems with 4.1.0 PL 2?
Reply With Quote
  #261  
Old 12-05-2010, 12:20 AM
CoZmicShReddeR's Avatar
CoZmicShReddeR CoZmicShReddeR is offline
 
Join Date: Sep 2006
Location: MI, USA
Posts: 338
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yeah I think I fixed mine I see steamprofile isn't working correctly I just edited mine seems to be fine...

I went to
edit style manager, edit templete, Postbit Template, postbit_gamercards_steam

just replace with this code should work but back up original code if it doesn't work...

Code:
<div class="block">
	<div class="blockhead">
		<span class="blockhead_info"><a class="textcontrol" href="javascript://" onclick="self.close()">{vb:rawphrase close_this_window}</a></span>
		<h2><img src="{vb:stylevar imgdir_misc}/gamericons/steam.png" width="16" height="16" alt="" /> {vb:rawphrase bc_gamercards_postbit_steamid}: <a href="http://steamcommunity.com/id/{vb:raw userinfo.steamid}" target="_blank">{vb:raw userinfo.steamid}</a></h2>
	</div>
	<div class="blockbody">
		<div class="blockrow">
			<div class="blockrow" align="center"><a href="http://steamcommunity.com/id/{vb:raw userinfo.steamid}" target="_blank"><img src="http://badges.steamprofile.com/profile/steam/{vb:raw userinfo.steamid}.png" alt="" border="0" /></a></div>
			<div class="blockrow" style="border-bottom:1px solid #c9c9c9; margin-bottom:5px; width:480px;"></div>
			<!-- <div class="blockrow"><a href="steam://friends/add/{vb:raw userinfo.steamid}" target="_blank">{vb:rawphrase bc_gamercards_add_x_friend, {vb:raw userinfo.steamid}}</a></div> -->
			<div class="blockrow"><a href="http://steamcommunity.com/id/{vb:raw userinfo.steamid}/friends" target="_blank">{vb:rawphrase bc_gamercards_x_friends_list, {vb:raw userinfo.steamid}}</a></div>
			<div class="blockrow"><a href="http://steamcommunity.com/id/{vb:raw userinfo.steamid}/games" target="_blank">{vb:rawphrase bc_gamercards_x_games_list, {vb:raw userinfo.steamid}}</a></div>
			<div class="blockrow">{vb:rawphrase bc_gamercards_x_status, {vb:raw userinfo.steamid}}<br /><img src="http://badges.steamprofile.com/profile/extended/steam/{vb:raw userinfo.steamid}.png" alt="" border="0" /></div>						
		</div>
	</div>
	<div class="blockfoot"></div>
</div>
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:24 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05264 seconds
  • Memory Usage 2,381KB
  • Queries Executed 26 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (3)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (3)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (7)postbit_attachment
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete