User:KeybladeSpyMaster/common.js

function changeImg(imgNumber)  { var myImages = ["https://lh3.googleusercontent.com/-j5jWIPTCRFI/U8gLaUPi4mI/AAAAAAAAASE/01-PG1yU34w/w736-h273-no/Kingdom_Hearts_Wiki_Logo.png", "https://lh4.googleusercontent.com/-TYRJvBBdLlo/U8gItOAyNjI/AAAAAAAAARA/y2FlZ1SDf2I/w161-h152-no/Wiki+Logo+KHHD25+%2528ver3%2529.png", "https://lh5.googleusercontent.com/-07c8LjWfkIA/U8gItIfbx9I/AAAAAAAAAQ8/Tr--sYbG00g/w161-h152-no/Wiki+Logo+KHHD25+%2528ver2%2529.png", "https://lh4.googleusercontent.com/-ziwpYa3MhLU/U8gKZ1CHPaI/AAAAAAAAARg/eje3jKlJqZg/w161-h152-no/Wiki+Logo+KHHD25+%2528ver4%2529.png"]; var imgShown = document#p-logo a.background-image; var newImgNumber =Math.floor(Math.random*myImages.length); document#p-logo a.background-image = 'url('+myImages[newImgNumber]+')'; } window.onload=changeImg;