Graham
For most browsers you do not need any code to add a favicon just the presence of a favicon.ico file in the root directory is enough for them to find and use it
just delete the old one and add a new favicon
once the browsers and xtgems image caches have cleared it will change