var origW;
var origH;
var proportions;

function setValues(imgx){
imgd = findDOM(imgx);
origW=imgd.width;
origH=imgd.height;
proportions=origH/origW;
}


function findDOM(objectId) {
if (document.getElementById) {
return (document.getElementById(objectId));}
if (document.all) {
return (document.all[objectId]);}
}

function reset(imgx){
imgd = findDOM(imgx);
imgd.width=origW;
imgd.height=origH;
}


function zoom(type,imgx,sz) {

imgd = findDOM(imgx);

if (type=="+" && imgd.width < 2500 ) {
imgd.width += 200;imgd.height += (200*sz);
}

if (type=="-" && imgd.width > 200 ) {
imgd.width -= 200;imgd.height -= (200*sz);
//alert("New Size "+imgd.width+"X"+imgd.height);
}

} 

function MouseAction(e){

if(navigator.appName=="Netscape") clickType=e.which;
else clickType=e.button;

if(clickType==1){
  zoom('+','myimg',proportions);
  return true;
}else{
  zoom('-','myimg',proportions);
  return false;
}

}

function clickIE() {if (document.all) {(message);return false;}}
function clickNS(e) {if 
(document.layers||(document.getElementById&&!document.all)) {
if (e.which==2||e.which==3) {(message);return false;}}}
if (document.layers) 
{document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;}
else{document.onmouseup=clickNS;document.oncontextmenu=clickIE;}

document.oncontextmenu=new Function("return false")

var showMes=1;

function show(item){
if(showMes) document.getElementById(item).style.visibility = "visible";
}

function hide(item){
document.getElementById(item).style.visibility = "hidden";
showMes=0;
}
