function togglenoteoff() {
        var bignote='bignote';
        document.getElementById(bignote).innerHTML='';
        document.getElementById(bignote).style.display='none';
}

function fireMyPopup(mypopup) {

// Determine how much the visitor had scrolled

var scrolledX, scrolledY;
if( self.pageYOffset ) {
  scrolledX = self.pageXOffset;
  scrolledY = self.pageYOffset;
} else if( document.documentElement && document.documentElement.scrollTop ) {
  scrolledX = document.documentElement.scrollLeft;
  scrolledY = document.documentElement.scrollTop;
} else if( document.body ) {
  scrolledX = document.body.scrollLeft;
  scrolledY = document.body.scrollTop;
}

// Determine the coordinates of the center of the page

var centerX, centerY;
if( self.innerHeight ) {
  centerX = self.innerWidth;
  centerY = self.innerHeight;
} else if( document.documentElement && document.documentElement.clientHeight ) {
  centerX = document.documentElement.clientWidth;
  centerY = document.documentElement.clientHeight;
} else if( document.body ) {
  centerX = document.body.clientWidth;
  centerY = document.body.clientHeight;
}


var leftOffset = scrolledX + (centerX - 500) / 2;
var topOffset = scrolledY + (centerY - 400) / 2;
  document.getElementById(mypopup).style.top = topOffset + "px";
  document.getElementById(mypopup).style.left = leftOffset + "px";
  document.getElementById(mypopup).style.display='block';
}

function togglenote(img,fit,title) {
        var bignote='bignote';
        document.getElementById(bignote).innerHTML='<span class=caption>'+title+'</span><BR><img src=".'+img+'" '+fit+'><div style="text-align:right;color:#777777;font-weight:bold;">Click to close</div>';
        fireMyPopup(bignote);
}


