// JavaScript Document

<!-- Begin Image preloader -->
		pics=new Array("btnAboutMe_002.gif, btnCVResume_002.gif, btnDesign_002.gif, btnProgramming_002.gif, btnPhotography_002.gif, btnInspiration_002.gif, btnResources_002.gif, pgCVResume.gif, pgDesign.gif, pgProgramming.gif, pgPhotography.gif, pgInspiration.gif, pgResources.gif" );
		for(imgnum=0;imgnum<pics.length;imgnum++)
			{
				imgfile=new Image();
				imgfile.src="../images/"+pics[imgnum];
			}
<!-- End Image preloader -->

/*
<!-- Begin extternal links xhtml strict alternative -->
function externalLinks() { 
  if (!document.getElementsByTagName) return; 
  var anchors = document.getElementsByTagName("a"); 
  for (var i=0; i<anchors.length; i++) { 
    var anchor = anchors[i]; 
    if (anchor.getAttribute("href") && 
        anchor.getAttribute("rel") == "external") 
      anchor.target = "_blank"; 
  } 
 } 
 window.onload = externalLinks;
<!-- End extternal links xhtml strict alternative -->
*/

<!-- Begin Image Popup Open Resize Center -->
//http://www.howtocreate.co.uk/perfectPopups.html
//<a href="ImageUrl" onclick="return popImage(this.href,'ImageTitle');">link</a>

//really not important (the first two should be small for Opera's sake)
PositionX = 0;
PositionY = 0;
defaultWidth  = 100;
defaultHeight = 100;

//kinda important
var AutoClose = true;

//don't touch
function popImage(imageURL,imageTitle,scrollbars,resizable)
	{
		var imgWin = window.open('','_blank',''+scrollbars+','+resizable+',title=yes,width='+defaultWidth+',height='+defaultHeight+',left='+PositionX+',top='+PositionY);
		if( !imgWin )
			{
				return true;
			} //popup blockers should not cause errors
		
			imgWin.document.write('<?xml version="1.0"?>');
			imgWin.document.write('<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml">');
			imgWin.document.write('<head>');
			imgWin.document.write('<title>'+imageTitle+'</title>');
			imgWin.document.write('<script type="text/javascript">');
				imgWin.document.write('function resizeWinTo()');
					imgWin.document.write('{');
						imgWin.document.write('if( !document.images.length )');
							imgWin.document.write('{');
								imgWin.document.write('document.images[0] = document.layers[0].images[0];');
							imgWin.document.write('}');
							
						imgWin.document.write('var oH = document.images[0].height, oW = document.images[0].width;');
						
						// Between here and the next comment keeps the image popup from being larger than screen when image is larger than screen.
						imgWin.document.write('if( window.opera )');
							imgWin.document.write('{');
								imgWin.document.write('var mH = screen.availHeight-300; var mW = screen.availWidth-150;');
								imgWin.document.write('if( oH > mH ) {oW =oW+16; oH = mH; }');
								imgWin.document.write('if( oW > mW ) { oW = mW; }');
						imgWin.document.write('}');
							
						imgWin.document.write('if(navigator.userAgent.indexOf("Netscape6")!=-1)');
							imgWin.document.write('{');
								imgWin.document.write('var mH = screen.availHeight-150; var mW = screen.availWidth-150;');
								imgWin.document.write('if( oH > mH ) { oH = mH; }');
								imgWin.document.write('if( oW > mW ) { oW = mW; }');
							imgWin.document.write('}');
						
						imgWin.document.write('if(navigator.userAgent.indexOf("Netscape")!=-1)');
							imgWin.document.write('{');
								imgWin.document.write('var mH = screen.availHeight-150; var mW = screen.availWidth-150;');
								imgWin.document.write('if( oH > mH ) { oW = oW+15; oH = mH; }');
								imgWin.document.write('if( oW > mW ) { oW = mW; }');
							imgWin.document.write('}');
							
						imgWin.document.write('if (navigator.userAgent.indexOf("Firefox")!=-1)');
							imgWin.document.write('{');
								imgWin.document.write('var mH = screen.availHeight-150; var mW = screen.availWidth-150;');
								imgWin.document.write('if( oH > mH ) { oW = oW+16; oH = mH; }');
								imgWin.document.write('if( oW > mW ) { oW = mW; }');
							imgWin.document.write('}');
							
						imgWin.document.write('if( !window.firefox && !window.netscape && !window.opera )');
							imgWin.document.write('{');
								imgWin.document.write('var mH = screen.availHeight-150; var mW = screen.availWidth-150;');
								imgWin.document.write('if( oH > mH ) { oH = mH; }');
								imgWin.document.write('if( oW > mW ) { oW = mW; }');
							imgWin.document.write('}');
						//End keep image popup from being larger than screen.
						
						imgWin.document.write('if( !oH || window.doneAlready )');
							imgWin.document.write('{');
								imgWin.document.write('return;');
							imgWin.document.write('}');
						imgWin.document.write('window.doneAlready = true;');
						
						imgWin.document.write('var x = window;');
						imgWin.document.write('x.resizeTo( oW + 200, oH + 200 );');
						imgWin.document.write('var myW = 0, myH = 0, d = x.document.documentElement, b = x.document.body;');
							imgWin.document.write('if( x.innerWidth )');
								imgWin.document.write('{');
									imgWin.document.write('myW = x.innerWidth; myH = x.innerHeight;');
								imgWin.document.write('}');
							imgWin.document.write('else if( d && d.clientWidth )');
								imgWin.document.write('{');
									imgWin.document.write('myW = d.clientWidth; myH = d.clientHeight;');
								imgWin.document.write('}');
							imgWin.document.write('else if( b && b.clientWidth )');
								imgWin.document.write('{');
									imgWin.document.write('myW = b.clientWidth; myH = b.clientHeight;');
								imgWin.document.write('}');
							imgWin.document.write('if( window.opera && !document.childNodes )');
								imgWin.document.write('{');
									imgWin.document.write('myW += 16;');
								imgWin.document.write('}');
						imgWin.document.write('x.resizeTo( oW = oW + ( ( oW + 200 ) - myW ), oH = oH + ( (oH + 200 ) - myH ) );');
						imgWin.document.write('var scW = screen.availWidth ? screen.availWidth : screen.width;');
						imgWin.document.write('var scH = screen.availHeight ? screen.availHeight : screen.height;');
							//imgWin.document.write('if( !window.opera )');
								//imgWin.document.write('{');
									imgWin.document.write('x.moveTo(Math.round((scW-oW)/2),Math.round((scH-oH)/2));');
								//imgWin.document.write('}');
					imgWin.document.write('}');
			imgWin.document.write('</script>');
			imgWin.document.write('</head>');
			imgWin.document.write('<body style="background: #FFFFFF text-align:center; colour:#FFFFFF; font-family:arial, sans-serif; font-size:12px;" onload="resizeWinTo();">');<!-- onblur="self.close();" -->
			// Make sure to specify correct location of the background url on next line for the animated Loading... gif.
			//You can copy the loading.gif to your site and use it from there, but please do not link to the image on my site.
			imgWin.document.write('<div style="position:absolute; top:0px; left:0px; background: url(../images/loading.gif) no-repeat top left;">');
			imgWin.document.write('<img style="display:block;" src='+imageURL+' alt="" title="" onload="resizeWinTo();" />');
			imgWin.document.write('</div>');
			imgWin.document.write('</body>');
			imgWin.document.write('</html>');
		
		imgWin.document.close();
		
		if( imgWin.focus )
			{
				imgWin.focus();
			}
		return false;
	}
<!-- End Image Popup Open Resize Center -->

<!-- Begin Bookmark -->
	function bookmark(url,title)
		{
			if(document.all && navigator.userAgent.toLowerCase().indexOf("mac")==-1) 	
					{
						window.external.AddFavorite(url,title);
					}
			
			else
				{
					alert('Your Browser does not support this feature! Press Cmmand+D MAC -or- Ctrl+D PC to add a bookmark for:\n"'+url+'".');
				}
		}
<!-- End Bookmark -->

<!-- Begin Print Page -->
	function printPage()
		{
			if(window.print)
				{
					window.print();
			return;
				}
				
			if(navigator.userAgent.toLowerCase().indexOf("mac")!=-1)
				{
					alert("Your Browser does not support this feature! Press Cmmand+P MAC -or- Ctrl+P PC");
			return;
				}
		}
//<a href="javascript:void(window.print())">
<!-- End Print Page -->