<!--

//--- check for browser
IE = ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion) >= 4 ));
//
NS = ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) >= 3 ));
//--- open pop-up window

function popup_picture(file, picturestring, WindowName, Width, Height) 
{ 
	var xposition=0; yposition=0;
//
    PageToLoad = "gallery.php?file=" + file + "&pix=" + picturestring;

    xposition = (screen.width - Width) / 2;
	yposition = (screen.height - Height) / 2;
//
	Args = 	"width="  + Width + "," 
	+ "height=" + Height + "," 
	+ "location=no," 
	+ "menubar=no,"
	+ "resizable=no,"
	+ "scrollbars=yes," 
	+ "status=no," 
	+ "titlebar=no,"
	+ "toolbar=no,"
	+ "hotkeys=no,";
//
	if (IE) Args = Args	+ 	"left=" + xposition + ","
	+	"top=" + yposition;
//
	if (NS) Args = Args 	+	"screenx=" + xposition + ","
	+	"screeny=" + yposition;
//
//--- open window
	window.open(PageToLoad, WindowName, Args);
}



function popup_page_preview(id, linktype, WindowName, Width, Height, language) 
{ 
	var xposition=0; yposition=0;
//
    PageToLoad = "../../../content/pagerenderer.php?link_type=" + linktype + "&id=" + id + "&lan=" + language + "&cms=1";

	xposition = (screen.width - Width) / 2;
	yposition = (screen.height - Height) / 2;
//
	Args = 	"width="  + Width + "," 
	+ "height=" + Height + "," 
	+ "location=no," 
	+ "menubar=no,"
	+ "resizable=no,"
	+ "scrollbars=yes,"
	+ "status=no," 
	+ "titlebar=no,"
	+ "toolbar=no,"
	+ "hotkeys=no,";
//
	if (IE) Args = Args	+ 	"left=" + xposition + ","
	+	"top=" + yposition;
//
	if (NS) Args = Args 	+	"screenx=" + xposition + ","
	+	"screeny=" + yposition;
//
//--- open window
	window.open(PageToLoad, WindowName, Args);
}



function popup_links(pid, eid, lan, WindowName, Width, Height) 
{ 
	var xposition=0; yposition=0;
//
    PageToLoad = "content_edit_links.php?pid=" + pid + "&eid=" + eid + "&lan=" + lan;

    xposition = (screen.width - Width) / 2;
	yposition = (screen.height - Height) / 2;
//
	Args = 	"width="  + Width + "," 
	+ "height=" + Height + "," 
	+ "location=no," 
	+ "menubar=no,"
	+ "resizable=no,"
	+ "scrollbars=yes," 
	+ "status=no," 
	+ "titlebar=no,"
	+ "toolbar=no,"
	+ "hotkeys=no,";
//
	if (IE) Args = Args	+ 	"left=" + xposition + ","
	+	"top=" + yposition;
//
	if (NS) Args = Args 	+	"screenx=" + xposition + ","
	+	"screeny=" + yposition;
//
//--- open window
	window.open(PageToLoad, WindowName, Args);
}


function popup_link_info(id, typ, WindowName, Width, Height) 
{ 
	var xposition=0; yposition=0;
//
    PageToLoad = "content_link_infos.php?id=" + id + "&type=" + typ;

    xposition = (screen.width - Width) / 2;
	yposition = (screen.height - Height) / 2;
//
	Args = 	"width="  + Width + "," 
	+ "height=" + Height + "," 
	+ "location=no," 
	+ "menubar=no,"
	+ "resizable=no,"
	+ "scrollbars=yes," 
	+ "status=no," 
	+ "titlebar=no,"
	+ "toolbar=no,"
	+ "hotkeys=no,";
//
	if (IE) Args = Args	+ 	"left=" + xposition + ","
	+	"top=" + yposition;
//
	if (NS) Args = Args 	+	"screenx=" + xposition + ","
	+	"screeny=" + yposition;
//
//--- open window
	window.open(PageToLoad, WindowName, Args);
}



function popup_search_result(s, lan, id, link_type, WindowName, Width, Height) 
{ 
	var xposition=0; yposition=0;
//
    PageToLoad = "content_renderer.php?id=" + id +  "&s=" + s + "&lan=" + lan + "&link_type=" + link_type;

    xposition = 40;
	yposition = 40;
//
	Args = 	"width="  + Width + "," 
	+ "height=" + Height + "," 
	+ "location=yes," 
	+ "menubar=yes,"
	+ "resizable=yes,"
	+ "scrollbars=yes," 
	+ "status=yes," 
	+ "titlebar=yes,"
	+ "toolbar=yes,"
	+ "hotkeys=yes,";
//
	if (IE) Args = Args	+ 	"left=" + xposition + ","
	+	"top=" + yposition;
//
	if (NS) Args = Args 	+	"screenx=" + xposition + ","
	+	"screeny=" + yposition;
//
//--- open window
	myWindow = window.open(PageToLoad, WindowName, Args);
	myWindow.focus();
}


function popup_print_page(link_id, s, lan, WindowName, Width, Height) 
{ 
	var xposition=0; yposition=0;
//
	PageToLoad = "pagerenderer.php?link_id=" + link_id + "&s=" + s + "&lan=" + lan + "&cms=1&print=1" ;

	xposition = (screen.width - Width) / 2;
	yposition = (screen.height - Height) / 2;
//
	Args = 	"width="  + Width + "," 
	+ "height=" + Height + "," 
	+ "location=no," 
	+ "menubar=no,"
	+ "resizable=no,"
	+ "scrollbars=yes,"
	+ "status=no," 
	+ "titlebar=no,"
	+ "toolbar=no,"
	+ "hotkeys=no,";
//
	if (IE) Args = Args	+ 	"left=" + xposition + ","
	+	"top=" + yposition;
//
	if (NS) Args = Args 	+	"screenx=" + xposition + ","
	+	"screeny=" + yposition;
//
//--- open window
	window.open(PageToLoad, WindowName, Args);
}

function activate_window()
{
	window.focus();
}


function send()
{
    document.forms["interactive_form"].submit();
}

