/* Function that swaps images. */
if (document.images) {
//	nav_sample = new Image(100,10); nav_sample.src = "http://url.com/file.gif";
}

function di20(id, newSrc) {
    var theImage = FWFindImage(document, id, 0);
    if (theImage) {
        theImage.src = newSrc;
    }
}

/* Functions that track and set toggle group button states. */
function FWFindImage(doc, name, j) {
    var theImage = false;
    if (doc.images) {
        theImage = doc.images[name];
    }
    if (theImage) {
        return theImage;
    }
    if (doc.layers) {
        for (j = 0; j < doc.layers.length; j++) {
            theImage = FWFindImage(doc.layers[j].document, name, 0);
            if (theImage) {
                return (theImage);
            }
        }
    }
    return (false);
}

function makeResizeableWindow(aName,aLink,aWidth,aHeight) {
        var remote

     /* per http://tech.irt.org/articles/js128/ -jpotter */
     if (document.all)
         var xMax = screen.width, yMax = screen.height;
     else
         if (document.layers)
             var xMax = window.outerWidth, yMax = window.outerHeight;
         else
             var xMax = 640, yMax=480;

     var xOffset = (xMax - aWidth)/2, yOffset = (yMax - aHeight)/2;

        remote = window.open(aLink ,aName,
               "width=" + aWidth + ",height=" + aHeight + 
               ",screenX=" + xOffset + ",screenY=" + yOffset + ",top=" + yOffset + ",left=" + xOffset + 
               ",scrollbars=yes,menubar=yes,status=no,resizable=yes");
        if (remote.opener == null) remote.opener = window;
        return;
}

