function popImage(pozaLINK,pozaTitlu,pozaMesaj,lang,WDTH,HGHT){

switch (lang)
{
case 'ro' : mesphoto=''; mescliq= 'clic pentru &icirc;nchidere'; break;
case 'en' : mesphoto=''; mescliq= 'click to close'; break;
default : mesphoto=''; mescliq= 'clic pentru &icirc;nchidere'; break;
}

	defaultWidth = WDTH;
	defaultHeight = HGHT;
	if ((WDTH > screen.width - 100) || (HGHT > screen.height - 300))
	{
	if ((WDTH - screen.width - 100) > (HGHT - screen.height - 300))
	{
	defaultWidth = screen.width - 300;
	defaultHeight = HGHT * (defaultWidth / WDTH);
	}
	else
	{
	defaultHeight = screen.height - 200;
	defaultWidth = WDTH * (defaultHeight / HGHT);
	}
	}

	PositionX = (screen.width-defaultWidth-100)/2;
	PositionY = (screen.height-defaultHeight-180)/2;
	var AutoClose = true;
	if (parseInt(navigator.appVersion.charAt(0))>=4){
		var isNN=(navigator.appName=="Netscape")?1:0;
		var isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}
	var optNN='scrollbars=no,width='+(defaultWidth+70)+',height='+(defaultHeight+100)+',left='+PositionX+',top='+PositionY;
	var optIE='scrollbars=auto,width='+(defaultWidth+70)+',height='+(defaultHeight+100)+',left='+PositionX+',top='+PositionY;


if (isNN){imgWin=window.open('about:blank','',optNN);}
	if (isIE){imgWin=window.open('about:blank','',optIE);}
with (imgWin.document){
	writeln('<html><head><title>Incarcare...</title>');
	writeln('<style type="text/css">');
	writeln('.stil { font-family: Verdana, Arial, Helvetica, sans-serif;');
	writeln('font-size: 12px; font-weight: bold; color: #0075EA;}')
	writeln('body { background-color: #DEE0D6;}');
	writeln('.stil1 {font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; font-style: italic; } </style>');
	writeln('<sc'+'ript>');
	writeln('var isNN,isIE;');writeln('if (parseInt(navigator.appVersion.charAt(0))>=4){');
	writeln('isNN=(navigator.appName=="Netscape")?1:0;');
	writeln('isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}');
	writeln('function doTitle(){document.title="'+pozaTitlu+'";}');
	writeln('</sc'+'ript>');
if (!AutoClose) writeln('</head><body scroll="no" onload="reSizeToImage();doTitle();self.focus()">')
else writeln('</head><body bgcolor=000000 scroll="no" onload="doTitle();self.focus()" onclick="self.close()" onblur="self.close()">');
	writeln('<table border="1" cellspacing="6" cellpadding="10" align="center"><tr><td align="center" valign="middle"><img name="echanges" width='+defaultWidth+' height='+defaultHeight+' src='+pozaLINK+' alt="'+pozaTitlu+'" style="display:block" border="1"> </td></tr></table>');
	writeln('<div align="center"><span class="stil"> '+pozaMesaj+' <br><br> </span><span class="stil1">- '+mescliq+' - </span></div></body></html>');
	close();		
}}
