Log in

View Full Version : Forum Display Enhancements - Xbox LIVE Gamercard in Postbit


GameOverViper
12-06-2011, 11:00 PM
Want to Add your Xbox LIVE Gamercard to Your Forum Postbit?

With just an addition of a profile field and one template edit, you'll have your Xbox LIVE Gamercard show up in the postbit in no time!

Demo - http://www.xboxoneclans.com/showthread.php?t=5888

If you already have the GamerCards Block in Profile mod (https://vborg.vbsupport.ru/showthread.php?t=232033), then you can simply use the Xbox Live profile field # that you created for the Xbox Live gamertag instead of creating a new profile field for your postbit.

If you already have the above mod, skip the next step.

Step 1 - Making the Profile Field


Create a new User Profile Field
Select "Single-Line Text Box"
Enter Gamertag as the title
Put, Enter your Xbox Live Gamertag Here, as your description
The rest of the settings are you up to you to decide


Remember to make a note of your Field Number that you have just created.

I put the gamercard under the users Avatar, but your free to place it where you want. Now you need to make one edit to the coding.

Step 2 - Go to postbit_legacy template

Find:

<vb:if condition="$show['avatar']">
<a class="postuseravatar" href="{vb:link member, {vb:raw post}}" title="{vb:rawphrase {vb:raw post['onlinestatusphrase']}, {vb:raw post.username}}">
<img src="{vb:raw post.avatarurl}" alt="{vb:rawphrase xs_avatar, {vb:raw post.username}}" />
</a>
</vb:if>


and after that, add:

<vb:if condition="$post['fieldX']">
<a class="postuseravatar">
<iframe src="http://gamercard.xbox.com/{vb:raw post.fieldX}.card" scrolling="no" frameBorder="0" height="140" width="204">{vb:raw post.fieldX}</iframe>
</a>
</vb:if>


Now in the code that you have just added, you need to change the 'X' with your Gamertag field number that you created earlier!

Step 3 - Changing the Width of the Postbit

Now the postbit width in default vB4.0 style is smaller than the gamercards actual size. You can edit the width of the post bit area to ensure that the Gamercard fits. To do this:


Go to Styles & Templates and select Style Manager.
Then select StyleVars for the theme your editing.
Find Postbitlegacy-Userinfo-Width.
Change the size to 220 and save.


Your finished.

thedarkroom
12-09-2011, 08:15 AM
thank you very much :)

GameOverViper
12-15-2011, 05:03 PM
thank you very much :)

Your welcome ;)

GamersChallenge
12-16-2011, 10:14 PM
look, who it is... good work bro, I was looking for this when I first started my site.

Gamelobby
04-11-2012, 04:55 AM
I guess this might be a question for the original mod, but i seem to be having an issue where it sends members to microsoft to sign in.?
login.live.com
I had only heard about it from members who were using Firefox, but now i actually saw it happen to me using Chrome.

GameOverViper
04-11-2012, 10:05 PM
I guess this might be a question for the original mod, but i seem to be having an issue where it sends members to microsoft to sign in.?
login.live.com
I had only heard about it from members who were using Firefox, but now i actually saw it happen to me using Chrome.

Can you post a screenshot? If you click the gamercard it will take you to that persons profile on xbox.com because that's how it's setup. However, I'm not sure where you talking about this showing up at.

Gamelobby
04-12-2012, 05:44 PM
Nothing pops up.. It literally takes you to microsoft.com completely changes sites.! (no new window, changes in the current window)
I don't have to click on anything, just load a page that has a gamer card on it & it loads microsoft.com login page.

I removed the cards from postbit because it was causing people a lot of problems, now it only happens on profile pages now. (not everytime, just occasionally)

It only happened to me once, but i have had reports from members that it wont let them go to certain pages without it happening.

Personally i notice it takes me back to the main forum page (forum.php) often when i go to a persons profile. (used to happen when reading new posts, before i removed them from postbit)

Not sure if it is an xbox.com issue, or a vB update issue, or a mod issue.. its just weird.

GameOverViper
04-15-2012, 11:40 AM
It's got to be an issue on your part, make sure you followed the instructions correctly. I'm currently using this on my xbox360clans.net website and it works perfectly fine on 4.1.12.

I know a couple other forums that also use it. So, that's why I believe it's something on your part.

Gamelobby
04-20-2012, 07:40 AM
Yea i have used this for a long time, but something recently must have triggered it.

GameOverViper
05-13-2012, 04:27 PM
Yea i have used this for a long time, but something recently must have triggered it.

Can I see an example? Screenshot or link.

insidegames
05-29-2012, 04:21 AM
Thanks for this Hack!

FTG LIQUID CL
07-09-2012, 04:10 PM
hey americanbang ,how did you get the different usergroups to show up like that in the screen shot you have

warrior uw
07-29-2012, 03:05 PM
why does this only work for me on my forum? everyone else has their gamertag and that put in correctly, but only my gamercard shows up in the postbit! Any ideas????

killerford
09-18-2012, 11:15 AM
Does this work with 4.2? I've done this on my 4.2 yet nothing is showing.

Gemma
09-19-2012, 09:37 PM
Does this work with 4.2? I've done this on my 4.2 yet nothing is showing.

Yes it works on vB4.2

GameOverViper
09-19-2012, 11:49 PM
hey americanbang ,how did you get the different usergroups to show up like that in the screen shot you have

I think your referring to the user rank images. However, you can change the color of usernames for each usergroup by changing the Username HTML Markup.

why does this only work for me on my forum? everyone else has their gamertag and that put in correctly, but only my gamercard shows up in the postbit! Any ideas????

If it's showing yours, then it's working as far as I know. Are you sure that the other peoples are valid gamertags? Invalid tags show up silver with no information because the gamertag doesn't exist.

Does this work with 4.2? I've done this on my 4.2 yet nothing is showing.

Yes it works, however today it's loading a little slow for some reason. They are hosted on xbox.com and they have been working on them a lot lately.

XGC Paravain
10-14-2012, 04:16 PM
Im trying to use this with my 4.2 I have done every thing it tells my, what am I doing wrong?

XGC Paravain
10-14-2012, 11:08 PM
Ok I have this working great on profiles its just not working right in the forums

XGC Paravain
10-16-2012, 01:50 AM
I got the Gamercard showing up in my profile but not my clan forums

Harpo
10-22-2012, 03:13 PM
Where do I add the code for vertical postbit?

Gamelobby
12-28-2012, 07:46 PM
Did something change recently.?
I upgraded to vB 4.2 & it seemed like it was working, but now all i get is an xbox.xom error page.
I see it is still working on your demo, so it must be on my end.

JamalFree
01-05-2013, 06:47 PM
thank you very much :):up::up::up:

marccap
02-06-2013, 11:08 PM
Works in 4.2 and I've coded a ps3 gamer card for 4.2 also which you can view in my site

Screen Capture (http://gyazo.com/67c2d22c0101a7cf4807089e60693fbc)

GameOverViper
02-08-2013, 10:16 PM
Ok I have this working great on profiles its just not working right in the forums

I got the Gamercard showing up in my profile but not my clan forums

From your screenshot that image not showing up is the missing image files for the gamercard plugin. You need to add the coding that I've listed into your postbit to get it to display the gamercard.

Where do I add the code for vertical postbit?

Should be the same place, near the avatar and post count information.

Works in 4.2 and I've coded a ps3 gamer card for 4.2 also which you can view in my site

Screen Capture (http://gyazo.com/67c2d22c0101a7cf4807089e60693fbc)

Thanks for sharing! Feel free to share the code you used for the PlayStation card to show up.

GameOverViper
08-29-2013, 02:58 AM
hey americanbang ,how did you get the different usergroups to show up like that in the screen shot you have

That's just the user ranks feature that's built into vbulletin already.

Gamelobby
10-10-2014, 02:36 AM
I think this died recently.??
All that pops up now is a small view of the xbox website. Slows the site down big time had to disable.

Anyone else.?

CAG CheechDogg
10-11-2014, 01:11 AM
I think this died recently.??
All that pops up now is a small view of the xbox website. Slows the site down big time had to disable.

Anyone else.?

Works fine on my site, the server was down a few days ago for a few hours but it works just fine ....