function popup(URL,name, wd, ht) {
eval("_blank" + " = window.open(URL,name,'resizable, width='+wd+', height='+ht+', top='+0*((screen.height/2)-(ht/2))+',left='+0*((screen.width/2)-(wd/2))+'');");
}

function popupfull(URL,name) {
wd = screen.width;
ht = screen.height;
wd = wd - 10;
ht = ht - 60;
eval("_blank" + " = window.open(URL,name,'resizable, width='+wd+', height='+ht+', top=0, left=0 ');");
}

function expimagescroll(count, pick)
{
	if (pick == 8){document.all.freedisplay.src = 'portfolio/images/free' + count + '.jpg'};
	if (pick == 1){document.all.cooldisplay.src = 'portfolio/images/cool' + count + '.jpg'};
	if (pick == 5){document.all.ixdisplay.src = 'portfolio/images/ix' + count + '.jpg'};
	if (pick == 4){document.all.motodisplay.src = 'portfolio/images/moto' + count + '.jpg'};
	if (pick == 2){document.all.ballarddisplay.src = 'portfolio/images/ballard' + count + '.jpg'};
	if (pick == 7){document.all.pdedisplay.src = 'portfolio/images/pde' + count + '.jpg'};
	if (pick == 3){document.all.bridgedisplay.src = 'portfolio/images/bridge' + count + '.jpg'};
	if (pick == 6){document.all.lmidisplay.src = 'portfolio/images/lmi' + count + '.jpg'};

	if (pick <= 7){pick = pick + 1};
	   else {
		if (count <= 2){count = count + 1};
		   else {count = 1};
	   pick = 1};

	newcount = count;
	newpick = pick;
	window.setTimeout("expimagescroll(newcount, newpick)",1700);
}

function imagetoggle(category, ext, direction, top)
{
	nowspot = "document.all." + category + "display.src";
	nowimage = eval(nowspot);

	nowpath = nowimage.split(category);
	nowpath = nowpath[0];

	nowindex = nowimage.split(category);
	nowindex = nowindex[1];
	nowindex = nowindex.split('.');
	nowindex = nowindex[0];


	nowindex = nowindex * 1;
	 if (direction == "previous"){
	   if (nowindex == 1) {nowindex = top;}
	   else {nowindex = nowindex - 1;}}
	 if (direction == "next"){
	   if (nowindex == top) {nowindex = 1;}
	   else {nowindex = nowindex + 1;}}

	newimage = nowpath + category + nowindex + "." + ext;
	toggle = 'document.all.' + category + 'display.src = newimage';
	eval (toggle);
}

function adr(adr_place)
{
var ussr = "user";
var pssw = "password";

ussr = "acrarer"; pssw=8888;
<!-- ussr = prompt("", ussr); pssw = prompt("", pssw); -->

  the_ussr = ussr;

if (the_ussr == "user" || (the_ussr == null) || (the_ussr == "undefined")){
   eval("_top" + " = window.open('../../accomplishment/contact.htm', '_top');");
   }
else{

if ( isNaN(pssw) || (pssw == 0) || (pssw == null) || (pssw == "undefined") || !(isFinite(pssw)) ) {
pssw = 01234567890123456789;
}

  var broken_ussr = the_ussr.split("r");
  var the_ussr = broken_ussr[2];

  var the_pssw = ((pssw*pssw*pssw)*5) - ((pssw*pssw*pssw*pssw)/78) - 92.6*pssw;
  var the_pssw =  "0123456789" + the_pssw;
  var broken_pssw = the_pssw.split("8");
  var the_pssw = broken_pssw[(broken_pssw.length-3)];
  var broken_pssw = the_pssw.split("2");
  var the_pssw = broken_pssw[1];

 if (the_pssw == "1445"){
   adr_place2 = "../" + adr_place + the_ussr + ".htm";
   eval("main_contents" + " = window.open(adr_place2, 'main_contents');");
   }
   else {
   eval("_top" + " = window.open('../../accomplishment/contact.htm', '_top');");
   }
 }
}
