
function View(form,txt) {
msg=open("","DisplayWindow","width=500,height=300,status=1,scrollbars=1");
msg.document.write("<html><head>");
msg.document.write("<title>UAP Admin - Text preview </title>");
msg.document.write("<link rel=\"stylesheet\" href=\"css/style.css\" type=\"text/css\">");
msg.document.write("<style>");
msg.document.write(" p {  text-align: justify} ")
msg.document.write("</style>");
msg.document.write("</head><body >");
msg.document.write("<table border=0><tr><td >");
msg.document.write("<p>");
msg.document.write(txt.value);
msg.document.write("</td></tr></table>");
msg.document.write("</body></html>");
}

function ViewTiny(form,txt) {
msg=open("","DisplayWindow","width=500,height=300,status=1,scrollbars=1");
msg.document.write("<html><head>");
msg.document.write("<title>UAP Admin - Text preview </title>");
msg.document.write("<link rel=\"stylesheet\" href=\"css/style.css\" type=\"text/css\">");
msg.document.write("<style>");
msg.document.write(" p {  text-align: justify} ")
msg.document.write("</style>");
msg.document.write("</head><body >");
msg.document.write("<table border=1 cellpadding=0 cellspacing=0 width=\"162\"><tr><td >");
msg.document.write(txt.value);
msg.document.write("</td></tr></table>");
msg.document.write("</body></html>");
}


function AddText(form, Action, txtelem){
var AddTxt="";
var txt="";
if(Action==1){  
txt=prompt("Enter text for HEADER1.","Text");      
if(txt!=null)           
AddTxt="<h1>"+txt+"</h1>\r\n";  
}
if(Action==2){  
txt=prompt("Enter text for HEADER2.","Text");      
if(txt!=null)           
AddTxt="<h2>"+txt+"</h2>\r\n";  
}
if(Action==3) AddTxt="&nbsp;";  
if(Action==4) {  
txt=prompt("Enter text for BOLD","Text");     
if(txt!=null)           
AddTxt="<b>"+txt+"</b>";        
}
if(Action==5) {  
txt=prompt("Enter text for ITALIC","Text");     
if(txt!=null)           
AddTxt="<i>"+txt+"</i>";        
}
if(Action==6) AddTxt="\r\n<p>";
if(Action==7) AddTxt="<BR>\r\n";
if(Action==8) AddTxt="<hr>\r\n";
if(Action==9) {  
txt=prompt("URL for link","http://");      
if(txt!=null){          
AddTxt="<a href="+txt+">";              
txt=prompt("Text for link","Text");              
AddTxt+=txt+"</a>\r\n";         
   }
}
if(Action==10) { 
txt=prompt("Image URL","URL");    
if(txt!=null)           
AddTxt="<img src="+txt+">\r\n"; 
}

txtelem.value+=AddTxt;
}

function OpenWin(address) {    
	var op_tool  =  0;    
	var op_loc_box  =  0;    
	var op_dir  =  0;    
	var op_stat  =  0;    
	var op_menu  =  0;    
	var op_scroll  =  1;    
	var op_resize  =  0;    
	var op_wid  = 360;   
	var op_heigh = 280;                 
	var option = "toolbar="+ op_tool +",location="+ op_loc_box +",directories=" 
+ op_dir +",status="+ op_stat +",menubar="+ op_menu +",scrollbars="  
+ op_scroll +",resizable="  + op_resize +",width=" + op_wid +",height="+ op_heigh +",left=100,top=100";
	var win3 = window.open("", "what_I_want", option);  
	var win4 = window.open(address, "what_I_want");
}

function AnunturiPassText(valoare) {
  document.forms[0].a_img.value = valoare;
}



function usure ( message, url ) {
	arethey = confirm(message)
	if (arethey) {location.href=url}
}

function showPic(picname,popwid,pophei)
{
if (!popwid || !pophei) {
popwid = 560;
pophei = 500;
}

window.open('http://www.anunt.look4u.ro/banc/popup_images.php?show=' + picname,'picture','width=' + popwid + ',height=' + pophei + ',resizable=yes,scrollbars=yes');
}