// JavaScript Document
function photo_open(link, width, height)
{
var photoWindow = window.open(link,"photo",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width='+width+',height='+height);
}
function openWindow(theURL,winName,features) {window.open(theURL,winName,features);}
function display(myimage) {
 html = "<html><head><title>Photo</title>" +
  "</head><body leftmargin=\"0\" " 
  + "marginwidth=\"0\" topmargin=\"0\" marginheight=\"0\"><center>" 
  + "<img style=\"cursor:pointer;\"src=\"" + myimage + "\" border=\"0\" name=\"image\" " 
  + "onload='window.resizeTo(document.image.width,document.image.height)'; onclick=\"window.close();\">"
  + "</center>" 
  + "</body></html>";
 popup=window.open('','image','toolbar=0,location=0,directories=0,menuBar=0,scrollbars=0,resizable=1');
 popup.document.open();
 popup.document.write(html);
 popup.document.close()
 };
  function doClear(theText) {
     if (theText.value == theText.defaultValue) {
         theText.value = ""
  }}

  	function set_language(id){
	var pars = 'get_lang='+id;
	 new Ajax.Request('client/ajax_modules/set_language.php',{method: 'get',parameters: pars,
		onLoading: function(){
	    $('loadingx').show();
		//alert('Let\'s see : '+form);
		},
		onSuccess: function(transport) {
		 var raspuns = transport.responseText;
		 //alert('Let\'s see : '+raspuns);
		 $('loadingx').hide();
		 getNewsLetter();
		 $('show_updatex').hide();
		 $(css2).hide();
		 $(css).innerHTML = raspuns;
		 $(css).show();
	   }  
    });
  }
  function getById(id){
	  return document.getElementById(id);
  }
  function showId(id){
	  
  }
function jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
////////////////////////
 function openWindow(url,win,feat) { //v2.0
  window.open(url,win,feat);
}
 function newsLetter(){	
	var forms = $('frmnws').serialize(true)
	new Ajax.Request('admin/ajax_modules/insert_news_letter.php', {
	method: 'post', parameters: forms,
			onLoading: function(){
				$('loading').show();
			},
			onSuccess: function(transport) {
				var raspuns = transport.responseText;
				$('news_lett').show();
				$('news_lett').innerHTML = raspuns;
				$('loading').hide();
			}
		});
	}