
function getParameter(str, name)
{
  var res = "";
  if (str.indexOf("?")!=-1)
  {
    str = str.substring(str.indexOf("?")+1, str.length);
    if (str.indexOf(name)!=-1)
    {
      if (str.indexOf("&", str.indexOf(name)+name.length)!=-1)
        res = str.substring(str.indexOf(name)+name.length+1, str.indexOf("&"))
	  else
        res = str.substring(str.indexOf(name)+name.length+1, str.length);
	}
  }
  return res;
}


function fPaypalOpen()
{
	wPaypal = window.open('','wPaypal','width=800,height=480,scrollbars=1,status=1,toolbar=1');
	wPaypal.focus();
}


function popup(adresa)
{
var w=570 , h=560;
var l=(screen.availWidth-w)/2 , t=(screen.availHeight-h)/2;
win=window.open(adresa,"_blank","width="+w+",height="+h+",left="+l+",top="+t+",statusbar=no,toolbar=no,scrollbars=no,navbar=no");
win.focus();
}

function fEvents()
{
var w=570 , h=460;
var l=(screen.availWidth-w)/2 , t=(screen.availHeight-h)/2;
win=window.open("events.htm","_blank","width="+w+",height="+h+",left="+l+",top="+t+",statusbar=no,toolbar=no,scrollbars=no,navbar=no");
win.focus();	
}

function bigImage(source,width,height)
{ //width,height are the one of the image not for the popup   //source=just the image name
var logo_h=100; //the feight for the logo
var popup_w=width , popup_h=height+logo_h;
var adresa="big_image.html?img="+source;
var l=(screen.availWidth-popup_w)/2 , t=(screen.availHeight-popup_h)/2;
win=window.open(adresa,"LargeImage","width="+popup_w+",height="+popup_h+",left="+l+",top="+t+",statusbar=no,toolbar=no,scrollbars=no,navbar=no");
win.focus();
}




function fStevie()
{
var w=570 , h=460;
var l=(screen.availWidth-w)/2 , t=(screen.availHeight-h)/2;
win=window.open("pet_stevie.htm","_blank","width="+w+",height="+h+",left="+l+",top="+t+",status=1,toolbar=no,scrollbars=1,navbar=no");
win.focus();	
}

function fPHDAnimals()
{
var w=570 , h=460;
var l=(screen.availWidth-w)/2 , t=(screen.availHeight-h)/2;
winpdh=window.open("phd_animals.htm","_blank","width="+w+",height="+h+",left="+l+",top="+t+",status=1,toolbar=no,scrollbars=1,navbar=no");
winpdh.focus();	
}


