/**************************************************



Author:  Eric King

URL:     http://redrival.com/eak/index.shtml

Name of script:

         EAK's ViewPic Script

leave this info in if you want to use the script.

do not alter or edit this script with out written 

permision.



**************************************************/



var win=null;



function ViewPic(myImg,myname,dogName,w,h,pos){



if(pos=="random"){

LeftPosition=(screen.width)?Math.floor(Math.random()*((screen.width-w)-75)):100;

TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}



if(pos=="center"){

LeftPosition=(screen.width)?(screen.width-w)/2:100;

TopPosition=(screen.height)?(screen.height-h)/2:100;}



else if((pos!="center" && pos!="random") || pos==null){

LeftPosition=0;

TopPosition=20}



settings='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars=no,resizable=no';

win=window.open("",myname,settings);

var picwin=win.document;



picwin.open();

picwin.write('<html><head><title>Shaankata - '+ dogName +'</title>');

picwin.write('<style type="text/css"><!--\n'+

             'div{font-family:"Trebuchet MS",MS Sans Serif, Geneva, sans-serif;font-size:'+(h*.1)+'px;font-weight:900;}'+

             '// --></style>');

picwin.write('<script language="javascript" type="text/javascript">'+

             '<!--\n'+'ns4=(document.layers)?1:0;\n'+'ie4=(document.all)?1:0;\n'+

             'function doit(){\n'+'if(ns4){document.loading.visibility="hide";}\n'+

             'else if(ie4){document.all.loading.style.visibility="hidden";}}\n'+'// --></sc'+'ript>');



picwin.write('</head><body onload="doit()" bgcolor="gray" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">');

picwin.write('<div id="loading" style="position:absolute;top:0;left:0;z-index:10;'+

             'width:'+w+';height:'+h+';clip:rect(0px '+w+'px '+h+'px 0px);'+

             'layer-background-color:gray;background-color:gray;padding:10px;">'+

             '</div>');

picwin.write('<img src="'+myImg+'" width="'+w+'" height="'+h+'" border="0" alt="">');

picwin.write('</body></html>');

picwin.close();

if(window.focus){win.focus();}

}



<!-- pedigree popup -->

var MyWin=null;

function dopopup1(mypopurl,mypopname,sizew,sizeh,poppos,auFoyer){

if(poppos=="center"){Left=(screen.width)?(screen.width-sizew)/2:100;Top=(screen.height)?(screen.height-sizeh)/2:100;}

else if((poppos!='center') || poppos==null){Left=+0;Top=+0}

Parms="width=" + sizew + ",height=" + sizeh + ",top=" + Top + ",left=" + Left + ",scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes";MyWin=window.open(mypopurl,mypopname,Parms);

MyWin.focus();}


