[Mod Release 1.3] Xbox Live Gamercard »  Show posts from    to     

Icy Phoenix


Old Customizations - [Mod Release 1.3] Xbox Live Gamercard



Chaotic [ Tue 15 Sep, 2009 18:23 ]
Post subject: [Mod Release 1.3] Xbox Live Gamercard
[Mod Release 1.3] Xbox Live Gamercard


xboxpic
This is slightly a MOD, but it is mainly a great customization many gaming websites may find useful.

This MOD will create a new custom profile field displaying your Xbox Gamertag, your Xbox Live Gamercard, and Friend Request/Live Message images on viewtopic.

To see this MOD in action, please visit: http://www.macommunity.net/viewtopic.php?f=12&t=2330

What is an Xbox LIVE Gamercard? A Gamercard shows your accumulated points earned by playing games, reputation, last five games played, etc. It's basically a way for everyone to see what you play and your Xbox LIVE Gamertag. Users are also able to click your Gamercard and add you to their Xbox LIVE Friends List. For more information about this, visit Xbox.com.

I'll be explaining how to do this in this topic and I'll be using the custom profile field DOC for the beginning instructions.


First, you want to create your Custom Profile Field via your ACP: ACP -> Users -> Add Custom Profile Fields

gamertag1

In this case, make sure the field is as seen in the picture: "xbox". We want to make the Xbox LIVE Gamercard viewable on viewtopic_body.tpl.

Next, open: viewtopic.php

FIND:

Code: [Hide] [Select]
$poster_from = ($postrow[$i]['user_from'] && $postrow[$i]['user_id'] != ANONYMOUS) ? $lang['Location'] . ': ' . $postrow[$i]['user_from'] : '';


AFTER, ADD:

Code: [Hide] [Select]
$poster_xbox = ($postrow[$i]['xbox'] && $postrow[$i]['user_id'] != ANONYMOUS) ? ('<a href="http://profile.mygamercard.net/' . urlencode($postrow[$i]['xbox']) . '"><img src="http://card.mygamercard.net/' . urlencode($postrow[$i]['xbox']) . '.png" /></a>') : '';

$poster_gtmessage_360 = ( $postrow[$i]['xbox'] && $postrow[$i]['user_id'] != ANONYMOUS ) ? '<a href="http://live.xbox.com/en-US/profile/MessageCenter/SendMessage.aspx?gt=' . urlencode($postrow[$i]['xbox']) . '" target="_blank"><img src="images/gm.png" alt="'. $lang['gtmessage'] .'" title="'. $lang['gtmessage'] .'" border="0" /></a>' : '';

$poster_gtadd_360 = ( $postrow[$i]['xbox'] && $postrow[$i]['xbox'] != ANONYMOUS ) ? '<a href="http://live.xbox.com/en-US/profile/FriendsMgmt.aspx?act=Add&ru=http://live.xbox.com/en-US/profile/Friends.aspx&amp;gt='. urlencode($postrow[$i]['xbox']) .'&AddAFriendSubmit=Add%20Friend" target="_blank"><img src="images/fr.png" alt="'. $lang['gtadd'] .'" title="'. $lang['gtadd'] .'" border="0" /></a>' : '';


Now we need to add the variable.

FIND:

Code: [Hide] [Select]
'POSTER_FROM' => $poster_from,


AFTER, ADD:

Code: [Hide] [Select]
'POSTER_XBOX' => $poster_xbox,
'POSTER_GTMESSAGE_360' => $poster_gtmessage_360,
'POSTER_GTADD_360' => $poster_gtadd_360,


Now we need to make the Gamercard viewable on viewtopic.

OPEN: viewtopic_body.tpl

FIND:

Code: [Hide] [Select]
<!-- END author_profile -->


AFTER, ADD:

Code: [Hide] [Select]
{postrow.POSTER_XBOX}<br />


FIND:

Code: [Hide] [Select]
{postrow.SKYPE_IMG}{postrow.YIM_IMG}


IN-LINE, AFTER ADD:

Code: [Hide] [Select]
{postrow.POSTER_GTMESSAGE_360}{postrow.POSTER_GTADD_360}


Now let's add the language variables for the Custom Profile Field and Friend Request/Live Message icons.

OPEN: lang_profile_fields.php

ADD:

Code: [Hide] [Select]
$lang['1_xbox'] = 'XBox ID';
$lang['1_Description'] = 'Insert your xbox gamers ID';


OPEN: lang_main.php

FIND:

Code: [Hide] [Select]
'Location' => 'Location',


AFTER, ADD:

Code: [Hide] [Select]
'gtmessage' => 'Send Me An Xbox Live Message',
'gtadd' => 'Send Me An Xbox Live Friend Request',


(CHANGE THE NUMBER TO YOUR CUSTOM PROFILE FIELD ID) (THIS CAN BE FOUND IN ACP -> USERS -> EDIT CUSTOM PROFILE FIELDS.)

Change the number "1" to whatever your Custom Profile Field is numbered. You may also change the text in this file to whatever you wish.


To place your Xbox Live Gamercard under the signature line instead of under post details:

OPEN: viewtopic_body.tpl

FIND AND REMOVE:

Code: [Hide] [Select]
{postrow.POSTER_XBOX}<br />


FIND:

Code: [Hide] [Select]
<span class="post-details"><br />{postrow.below_sig.BELOW_VAL}</span>
<!-- END below_sig -->
</div>


ADD AFTER:

Code: [Hide] [Select]
<br /><br />{postrow.POSTER_XBOX}<br />


Make sure to upload the images attached to this post to: your_ip_root/images/

You can move the Xbox Live Gamercard, Friend Request/Live Message icons anywhere you please!

Please post your questions, ideas, suggestions in this topic so all may contribute!


Lopalong [ Wed 16 Sep, 2009 16:56 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
Nice,

Only one thing - Move all the language into a lang_extend_xbox.php file as it will not only save two edit's, it decreases the chance of two more options to stuff something up!

It's also easier for translations etc - And if you need someone to do it - Yell out!


DWho [ Wed 16 Sep, 2009 18:33 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
Very nice work Gary!



habichtha [ Sun 29 Nov, 2009 10:46 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
How much can you trade in xbox 360 at gamestop without wires and hardrive? I need to save up for xbox arcade because I would prefer the newer xbox because they have less problems and more hdmi, but I want to keep my hardrive. So how much can I get for an xbox 360 pro(2006) without wires and hardrive.


n1cks21 [ Wed 16 Dec, 2009 16:53 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
got your mod working a treat but I made a slight change to make it more colorful

in viewtopic.php I changed http://card.mygamercard.net/ to http://card.mygamercard.net/lastgame/

which makes some (not all) games show on the gamercard background i.e.

http://card.mygamercard.net/ gives this pic

ped_117a

but changing to this
http://card.mygamercard.net/lastgame/

ped_117

and the background pic will change depending on what game you last played, this DOES NOT WORK for all games, some backgrounds make the text hard to read and some dont but overall it makes the cards more colorful..............

thanks for the original mod


Chaotic [ Mon 28 Dec, 2009 18:32 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
Great idea and thanks for sharing.

I just chose the simpler version because I didn't want mygamercard.net being linked to on my site. Just a preference.


Chaotic [ Wed 30 Dec, 2009 18:07 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
Just found this out. To apply the changes n1cks21 made and for it to work, you'll need to have a mygamercard.net user account. Otherwise the gamercard will look normal and not show the last game you played.


GalaxiaNaruto [ Sat 01 Jan, 2011 19:14 ]
Post subject: Re: [Mod Release 1.3] Xbox Live Gamercard
I think I've done everything necessary to install, but It does not work. My Icy´s version is 1.3.0.5a

Regards, sorry for my english(i´m spanish) and a happy new year 2011!




Powered by Icy Phoenix