User Pass
Home Sign Up Contact Log In
AC
offline
Link
 
Anyone know of a script that adds the player avatars to the team roster page? I know there is an older version, but it doesn't work with the newer roster page.
 
kjoe51689
offline
Link
 
Code it
 
AC
offline
Link
 
Originally posted by kjoe51689
Code it


I don't know how to do that. Thanks Joe.
 
pabst
offline
Link
 
The real question is ... why would you really want that?

// ==UserScript==
// @name avatars on roster
// @namespace pbr/aor
// @include http://goallineblitz.com/game/roster.pl?team_id=*
// ==/UserScript==

for (var j=0; j<document.getElementsByClassName("player_name").length; j++) {
var pn = document.getElementsByClassName("player_name")[j];
var pid = parseInt(pn.firstChild.firstChild.href.toString().split("=")[1]);
var img = document.createElement("img");
img.src = "/game/player_pic.pl?player_id="+pid;
img.width = 32;
img.height = 32;
pn.firstChild.insertBefore(img, pn.firstChild.firstChild);
}
 
defaultzero
offline
Link
 
Pabst.. You are magic
 
AC
offline
Link
 
Thanks!
 


You are not logged in. Please log in if you want to post a reply.