/*

JAVASCRIPT LIBRARY

*/

var _js_home_dir = 'toolbox/';
document.write('<script src="'+_js_home_dir+'CalendarPopup.js"></script>');

// BUTTONCLICK: oldal betöltése
function ButtonClick(url) {
  window.location = url;
  }

// CONFIRMDELETE: a rekord törlését megerősítő kérdést követően megnyitja a megadott oldalt
function ConfirmDelete(url,text) {
  if (text==undefined) errMsg='Valóban törölni szeretné a kiválasztott elemet?'; else errMsg=text;
  if (window.confirm(errMsg)) window.location=url;
  }
  
function miniablak_nyit(kiirando_szoveg, cim){
alert('a');
  var inlinewin=dhtmlwindow.open("broadcastbox", "inline", kiirando_szoveg, cim, "width=500px,height=400px,left=150px,top=10px,resize=1,scrolling=1", "recal")
  inlinewin.show();
}  

function miniablak_nyit_iframe(kiirando_szoveg, cim, left, top, width, height){
  var inlinewin2=dhtmlwindow.open("broadcastbox2", "iframe", kiirando_szoveg, cim, "width="+width+"px,height="+height+"px,left="+left+"px,top="+top+"px,resize=1,scrolling=0", "recal")
  inlinewin2.show();
} 

		
// DATEPICKER: 
function DatePicker(mezonev,defvalue) {
	id = 'id_' + Math.random() * Math.pow(10, 17);
	html = '';
	html = html + '<table cellspacing="0" cellpadding="0"><tr><td>';
	html = html + '<input name="'+mezonev+'" id="'+id+'" value="'+defvalue+'" size="14">';
	html = html + '</td><td>';
	html = html + '<a href="javascript:displayDatePicker(\''+id+'\')">';
	html = html + '<img src="'+_js_home_dir+'calendar_icon.gif" BORDER="0" ALT="Dátumválasztó"></a>';
	html = html + '</td></tr></table>';
	document.write(html);
	}


	
// DATETIMEPICKER: 
function DateTimePicker(datummezo, idomezo, datumdef, idodef) {
	id = 'id_' + Math.random() * Math.pow(10, 17);
	html = '';
	html = html + '<table cellspacing="0" cellpadding="0"><tr><td>';
	html = html + '<input name="'+datummezo+'" id="'+id+'" value="'+datumdef+'" size="14">';
	html = html + '</td><td>';
	html = html + '<a href="javascript:displayDatePicker(\''+id+'\')">';
	html = html + '<img src="'+_js_home_dir+'calendar_icon.gif" BORDER="0" ALT="Dátumválasztó"></a>';
	html = html + '</td>';
	html = html + '<td><input type="text" name="'+idomezo+'" value="'+idodef+'" maxlength="5" size="6"></td>';
	html = html + '</tr></table>';
	document.write(html);
	}	
