	function topimg(l_plotis,l_aukstis,imgurl)
	{
		var l_aukstis2 = l_aukstis + 0;		// lango aukstis
		var l_plotis2 = l_plotis + 0;			// lango plotis
		var winl = screen.width/2-l_plotis/2;
		var wint = screen.height/2-l_aukstis/2;
		var randomnumber=Math.floor(Math.random()*1001);
		var newWindow = window.open('http://www.impro.lt/inc/topimg.php?'+imgurl,'I'+randomnumber,'height='+l_aukstis2+',width='+l_plotis2+',top='+wint+',left='+winl+',  buttons=no, scrollbars=no, location=no, menubar=no, resizable=no, status=no, directories=no, toolbar=no');
	}
	/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
	function topvideo(videourl)
	{
		var l_aukstis = 240 + 80;		// lango aukstis
		var l_plotis = 320 + 20;		// lango plotis
		var winl = screen.width/2-l_plotis/2;
		var wint = screen.height/2-l_aukstis/2;
		var randomnumber=Math.floor(Math.random()*1001);
		var newWindow = window.open('http://www.impro.lt/inc/topvideo.php?'+videourl,'V'+randomnumber,'height='+l_aukstis+',width='+l_plotis+',top='+wint+',left='+winl+',  buttons=no, scrollbars=no, location=no, menubar=no, resizable=no, status=no, directories=no, toolbar=no');
	}
	/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
	function topaudio(audiourl)
	{
		var l_aukstis = 30 + 10;		// lango aukstis
		var l_plotis = 210 + 10;		// lango plotis
		var winl = screen.width/2-l_plotis/2;
		var wint = screen.height/2-l_aukstis/2;
		var randomnumber=Math.floor(Math.random()*1001);
		var newWindow = window.open('http://www.impro.lt/inc/topaudio.php?'+audiourl,'A'+randomnumber,'height='+l_aukstis+',width='+l_plotis+',top='+wint+',left='+winl+',  buttons=no, scrollbars=no, location=no, menubar=no, resizable=no, status=no, directories=no, toolbar=no');
	}
	/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
	function topimgx(l_plotis,l_aukstis,imgurl,title)
	{
		var l_aukstis2 = l_aukstis + 20;		// lango aukstis
		var l_plotis2 = l_plotis + 20;			// lango plotis
		if (title!=true) { var title2 = (Math.round((Math.random()*999)+1)); }	else { var title2="mg"; }
		var winl = screen.width/2-l_plotis/2;
		var wint = screen.height/2-l_aukstis/2;
		var randomnumber=Math.floor(Math.random()*1001);
		var newWindow = window.open('http://www.impro.lt/inc/topimg.php?'+imgurl, "IM"+title2, 'height='+l_aukstis2+', width='+l_plotis2+', top='+wint+', left='+winl+', buttons=no, scrollbars=no, location=no, menubar=no, resizable=no, status=no, directories=no, toolbar=no');
	}
	/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
	function toppage(l_plotis,l_aukstis,id)
	{
		var winl = screen.width/2-l_plotis/2;
		var wint = screen.height/2-l_aukstis/2;
		var randomnumber=Math.floor(Math.random()*1001);
		var newWindow = window.open('http://www.impro.lt/inc/toppage.php?'+id,'P'+randomnumber,'height='+l_aukstis+',width='+l_plotis+',top='+wint+',left='+winl+', buttons=no, scrollbars=no, location=no, menubar=no, resizable=no, status=no, directories=no, toolbar=no');
	}
	
	/*
	function write_mediapro_Swf()
	{
		document.write("<div id='mediapro_flash' style='position:absolute; top:0px; left:296px; z-index:1; width:510px; height:455px;'>");

		document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0' width='510' height='455' id='mediapro' align='middle'>");
		document.write("<param name='allowScriptAccess' value='sameDomain' />");
		document.write("<param name='movie' value='img/mediapro.swf' /><param name='quality' value='high' /><param name='scale' value='noscale' /><param name='wmode' value='transparent' /><param name='bgcolor' value='#f8f7f6' />");
		document.write("<embed src='img/mediapro.swf' quality='high' scale='noscale' wmode='transparent' bgcolor='#f8f7f6' width='510' height='455' name='mediapro' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
		document.write("</object></div>");
	}
		

	
	function write_menu_swf(nuoroda, title, status, id){
		document.write("<table cellpadding='0' cellspacing='0' border='0'>");
		document.write("<tr><td width='187'>");
		document.write("<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0' width='187' height='12'>");
		document.write("<param name='movie' value='img/meniu.swf?mas="+status+"&mp="+title+"&mn="+nuoroda+"&mi="+id+"' />");
        document.write("<param name='quality' value='high' />");
		document.write("<param name='bgcolor' value='#f8f7f6' />");
		document.write("<embed src='img/meniu.swf?mas="+status+"&mp="+title+"&mn="+nuoroda+"&mi="+id+"' type='application/x-shockwave-flash' quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' bgcolor='#f8f7f6' menu='false' type='application/x-shockwave-flash' width='187' height='12'/>");
		document.write("</object>");
		document.write("</tr></td>");
		document.write("<tr><td><img src='img/blank.gif' border='0' height='1' alt=''></td></tr>");
		document.write("</table>");
	}
	
	function write_menu_html(nuoroda, title, status, ftpLink) {
		document.write("<table cellpadding='0' cellspacing='0' border='0'>");
		document.write("<tr>");
		document.write("<td width='200' valign='top'");
		if (status!="yes") {
			//document.write("onMouseover=\"this.style.backgroundColor='#575757'; this.style.color='#FFFFFF';  this.style.backgroundImage='url(img/rodykle.gif)'; this.style.backgroundPosition='right bottom'; this.style.backgroundRepeat='no-repeat';\" ");
			//document.write("onMouseout=\"this.style.backgroundColor='#F6F6F6'; this.style.color='#222222'; this.style.backgroundImage='url(img/blank.gif)'; this.style.backgroundPosition='right'; this.style.backgroundRepeat='no-repeat';\" ");
		}
		document.write("class=\"meniu");
		if (status=="yes") {
			//document.write("_on");
			on='_on';
		} else on='';
	
		if(ftpLink==1) blank="target=''"; else blank="";
		
		document.write("\" id='menuLink"+on+"'><a href='"+nuoroda+"' "+blank+">"+title+"</a></td>");
		document.write("<td><img src='blank.gif' height='1' width='15'></td></tr>");
		document.write("<tr><td colspan='2'><img src='img/blank.gif' border='0' height='1'></td></tr>");
		document.write("</table>");
	}
	
	function write_title_swf (file,title,width,height)
	{
		document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0' width='"+width+"' height='"+height+"' id='title' align='middle'>");
		document.write("<param name='allowScriptAccess' value='sameDomain' />");
		document.write("<param name='movie' value='img/"+file+".swf"+title+"' />");
		document.write("<param name='quality' value='high' />");
		document.write("<param name='wmode' value='transparent' />");
		document.write("<param name='bgcolor' value='#f8f7f6' />");
		document.write("<embed src='img/"+file+".swf"+title+"' quality='high' bgcolor='#f8f7f6' wmode='transparent' width='"+width+"' height='"+height+"' name='title' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
		document.write("</object>");
	}
	
	function write_title_html (title)
	{
		document.write("<img src='img/title_arrow.gif' alt=''/>");
		document.write("<span class='title'>"+title+"</span>");
	}
	
	function write_subtitle_html (subtitle) {
		document.write("<span class='subtitle'>"+subtitle+"</span>");
	}
	
	function write_html_link (ending){
		document.write("<a class='pink' href='./"+ending+"/'>html versija</a>");
	}
		
	function flash_check() {
		with (navigator) if (appName.indexOf('Microsoft')!=-1 && appVersion.indexOf('Mac')==-1) document.write(''+
		'<scr'+'ipt language="VBScript">\nOn error resume next\n'+
		'MM_dir = IsObject(CreateObject("SWCtl.SWCtl.1"))\n'+
		'MM_flash = NOT IsNull(CreateObject("ShockwaveFlash.ShockwaveFlash"))\n</scr'+'ipt>');	
	}
		
	function checkPlugin(plgIn) { //v4.0
	  var ok=false; 
	  //document.MM_returnValue = false;
	  with (navigator) if (appName.indexOf('Microsoft')==-1 || (plugins && plugins.length)) {
		ok=(plugins && plugins[plgIn]);
	  } else if (appVersion.indexOf('3.1')==-1) { //not Netscape or Win3.1
		if (plgIn.indexOf("Flash")!=-1 && window.MM_flash!=null) ok=window.MM_flash;
		else if (plgIn.indexOf("Director")!=-1 && window.MM_dir!=null) ok=window.MM_dir;
		}
	  if (!ok){ flash=false;} else { flash=true; }
	  //alert(flash);	
	  return flash;  
	}
	*/
