/* Set align/float to none on images wider than n px */
function imageFix(){
    va = document.getElementById("viewarea");
    if (va){
        imgs = va.getElementsByTagName("img");
        i = 0;
        for (i = 0; i<imgs.length; i++){
            currentimg = imgs[i];
            if (parseInt(currentimg.width) > 550){
                currentimg.style.cssFloat = 'none';
                currentimg.width = '550';
                currentimg.align = '';
            } 
        }
    }

}

function changeImages(imageId, imageSrc){
    document.getElementById(imageId).src = imageSrc;
}
function newImage(imgSrc)
{
    img = new Image();
    img.src = imgSrc;
    return img;
}
