dudeamis
|
trying to edit the replay avatar script// ==UserScript==
// @name individual avatars
// @namespace Dudeamis Griff
// @description individual animated gifs for every player
// @include http://goallineblitz.com/game/replay.pl?pbp_id=*
// ==/UserScript==
window.setTimeout( function()
{
var allDivs, thisDiv, id;
allDivs = document.evaluate(
"//*[@class='player_icon']", //FIND THOSE PLAYERS
document,
null,
XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,
null);
for (var i = 0; i < allDivs.snapshotLength; i++)
{
thisDiv = allDivs.snapshotItem(i);
id = thisDiv.id; //WHERE DA ID AT
if (id=='ball')
{thisDiv.innerHTML = '<img src="http://goallineblitz.com/images/ball.gif">';}
else if (id == 'ds') //fixes conflict with first down marker script
{}
else if (id == '161879') //Dylan Griffiths
{thisDiv.innerHTML = '<img src="http://i184.photobucket.com/albums/x276/dudeamis/backtest.png'">';}
else
{thisDiv.innerHTML = '<img src="http://goallineblitz.com/game/player_pic.pl?player_id=' + id + '"width=12 height=12>';}
}
}
)
but its not working... what am I doing wrong?
|