
/*{{{ init... */

var ShowPictureUrl = '';
var ShowPictureText = '';
var ShowPictureW = 240;
var ShowPictureH = 240;
var ShowPictureBigW = 350;
var ShowPictureBigH = 250;

/*}}}*/

function escHtml (s)/*{{{*/
{
	//s = String ( s );
	s = s.replace(/\&/g,'&amp;');
	s = s.replace(/\"/g,'&quot;');
	s = s.replace(/\«/g,'&laquo;');
	s = s.replace(/\»/g,'&raquo;');
	return s;
}/*}}}*/

function ShowPicture (o)/*{{{*/
{
	if ( !o || !o.href ) { return true; }

	var href = String ( o.href );

	var alt = '';
	if ( o.firstChild && o.firstChild.alt ) {
		alt = o.firstChild.alt;
	}

	ShowPictureUrl = href;
	ShowPictureText = escHtml(alt);

	var w = ShowPictureW + 120;
	var h = ShowPictureH + 200;
	var x = Math.floor ( (screen.width-w) / 2 );
	var y = Math.floor ( (screen.height-h) / 2 );

	var url = '/Picture.htm';
	var id = '_ShowPicture';

	var props = "dependent=yes";
	props += ",location=no";
	props += ",statusbar=no,menubar=no";
	props += ",resizable=yes,scrollbars=no";
	props += ",width="+w+",height="+h;
	props += ",left="+x+",top="+y;

	var win = window.open(url, id, props);

	return false;

}/*}}}*/
function ShowPictureBig (o)/*{{{*/
{
	if ( !o || !o.href ) { return true; }

	var href = String ( o.href );

	var alt = '';
	if ( o.firstChild && o.firstChild.alt ) {
		alt = o.firstChild.alt;
	}

	ShowPictureUrl = href;
	ShowPictureText = escHtml(alt);

	var w = ShowPictureBigW + 120;
	var h = ShowPictureBigH + 220;
	var x = Math.floor ( (screen.width-w) / 2 );
	var y = Math.floor ( (screen.height-h) / 2 );

	var url = '/PictureBig.htm';
	var id = '_ShowPicture';

	var props = "dependent=yes";
	props += ",location=no";
	props += ",statusbar=no,menubar=no";
	props += ",resizable=yes,scrollbars=no";
	props += ",width="+w+",height="+h;
	props += ",left="+x+",top="+y;

	var win = window.open(url, id, props);

	return false;

}/*}}}*/
function ShowPictureBigX (o)/*{{{*/
{
	if ( !o || !o.href ) { return true; }

	var href = String ( o.href );

	var alt = '';
	if ( o.firstChild && o.firstChild.alt ) {
		alt = o.firstChild.alt;
	}

	ShowPictureUrl = href;
	ShowPictureText = escHtml(alt);

	var w = ShowPictureBigH + 120;
	var h = ShowPictureBigW + 220;
	var x = Math.floor ( (screen.width-w) / 2 );
	var y = Math.floor ( (screen.height-h) / 2 );

	var url = '/PictureBigX.htm';
	var id = '_ShowPicture';

	var props = "dependent=yes";
	props += ",location=no";
	props += ",statusbar=no,menubar=no";
	props += ",resizable=yes,scrollbars=no";
	props += ",width="+w+",height="+h;
	props += ",left="+x+",top="+y;

	var win = window.open(url, id, props);

	return false;

}/*}}}*/
function OpenPopup (url,w,h)/*{{{*/
{
	if ( !Number(w) ) { w = 640; }
	if ( !Number(h) ) { h = 480; }

	var x = Math.floor ( (screen.width-w) / 2 );
	var y = Math.floor ( (screen.height-h) / 2 );

	var id = '_Popup';

	var props = "dependent=yes";
	props += ",location=no";
	props += ",statusbar=no,menubar=no";
	props += ",resizable=yes,scrollbars=yes";
	props += ",width="+w+",height="+h;
	props += ",left="+x+",top="+y;

	var win = window.open(url, id, props);

	return false;

}/*}}}*/


