/*
	Auto center window script- Eric King (http://redrival.com/eak/index.shtml)
	Permission granted to Dynamic Drive to feature script in archive
	For full source, usage terms, and 100's more DHTML scripts, visit http://dynamicdrive.com
	*/
	
	var win = null;
	function NewWindow(mypage,myname,w,h,scroll){
	LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
	TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
	settings =
	'height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable'
	win = window.open(mypage,myname,settings)
	}
	
// ------------------------- Ivan Borzov -----------------------------
// This script show the various texts in order.
// Example: ShowNext('id1','id2',5,1)
// Where: id1, id2 - objects ID
//              5 - number of objects with eaqual ID
//              1 - show direction ( "1" - forward, "-1" - backward)
//current=0;
//next=0;
function ShowNext(a,d,b,c)
{
for (i=0; i<b; i++) {
	IdName = a+i;
	Content=document.getElementById(IdName);
	state=Content.style.display;
	if (state=="block"){current=i;}
    }
next=current+c;
if(next==b) { next=0; }
if(next==-1) { next=b-1; }
Content=document.getElementById(a+current);
Content.style.display="none";
Content=document.getElementById(a+next);
Content.style.display="block";
Content=document.getElementById(d+current);
Content.style.display="none";
Content=document.getElementById(d+next);
Content.style.display="block";
current=next;
}