function proclink(info) {
   parent.location = rot13('znvygb:') + rot13(info);
}

function rot13(text) {
   var S2b='';
   for(var J7=0;J7<text.length;J7++) {
      var C6=text.charCodeAt(J7);
      if(Math.abs(16-Math.abs(C6-93.5))<=13) {
         W8b=(C6<91)?65:97;
         S2b+=String.fromCharCode(((C6-W8b+13)%26)+W8b);
      } else {
         S2b+=text.charAt(J7);
      }
   }
   return S2b;
}

function copyrightdates() {
	var strReturn = '<span style="font-size: 7.2pt">Copyright &copy; 2007 by Valley Horse Journal. All Rights Reserved. Site Design by MicroArtisans.</span>';
	return strReturn;
}

function OpenPicture(Link, Width, Height) {
	var newWindow, newWidth, newHeight;
	var newLeft, newTop;
	
	newWidth = (window.screen.availWidth * 9) / 10;
	newHeight = (window.screen.availHeight * 9) / 10;
	
	if ((Height <= newHeight) && (Width <= newWidth)) {
		newLeft = (window.screen.availWidth - newWidth) / 2;
		newTop = (window.screen.availHeight - newHeight) / 2;
		newWidth = Width;
		newHeight= Height;
	} else if ((newHeight / Height) < (newWidth / Width)) {
		newTop = (window.screen.availHeight - newHeight) / 2;
		newWidth = (Width * newHeight) / Height;
		newLeft = (window.screen.availWidth - newWidth) / 2;
	} else {
		newLeft = (window.screen.availWidth - newWidth) / 2;
		newHeight = (Height * newWidth) / Width;
		newTop = (window.screen.availHeight - newHeight) / 2;
	}
	
	newWindow = window.open("", "sub", "resizable,innerHeight=" + newHeight + ",innerWidth=" + newWidth);
	newWindow.focus();
	newWindow.resizeTo(newWidth, newHeight);
	newWindow.moveTo(newLeft, newTop);
	
	var newContent = "<html><head><title>Photograph</title></head>\n";
	newContent += "<body leftmargin=0 bottommargin=0 topmargin=0 rightmargin=0>\n";
	newContent += "<img src='" + Link + "' border=0 width=" + newWidth + " height=" + newHeight + " align=center>\n";
	newContent += "</body>\n</html>\n";
	newWindow.document.write(newContent);
	newWindow.document.close();
}


