// client-side scripts

function openWin(sURL,hostname_in) {
//param 1 = url
//param 2 = hostname
// prompt_user =  whether to prompt or not (0 = no prompt, 1 or missing = prompt user)

var hostname = "";

if (arguments.length == 2)
{
hostname = hostname_in;
}

// set default
var prompt_user = 0;

//check hostname - set if remote document to see if it's an lbc one and suppress prompt if it is
if (sURL.indexOf('ejpd.admin.ch') != -1) // i.e. it DOES contain that string
{
	prompt_user = 0;
}

if (hostname.indexOf('ejpd.admin.ch') != -1) // i.e. it DOES contain that string
{
	prompt_user = 0;
}

if (prompt_user == 1)
{
alert("You are now leaving our site. \n ejpd.admin.ch is not responsible for the content of external internet sites.");

windowHandle=window.open(sURL,'newwin');
}
else
{

windowHandle=window.open(sURL,'newwin','copyhistory=no, scrollbars=yes, toolbar=no, location=no, status=yes, directories=no, menubar=no, resizable=yes, status=yes, width=900, height=650, left=0, top=0');

}

}