function show_picture(my_image_id, my_imageurl, my_imagewidth, my_imageheight){
	var windowName = "theprtnewsspopup" + my_image_id;
	var newwin;
	var params = "width=" + (my_imagewidth + 0) + ", height=" + (my_imageheight + 0) + ",resizable=no,status=no";
	var window_left = (screen.width-my_imagewidth)/2;
	var window_top = (screen.height-my_imageheight)/2;
	newwin = window.open( "" , windowName ,  params ) 
			with(newwin.document){
				write("<html>\n");
				write("<head>\n");
				write("<title>Bild</title>\n");
				write("</head>\n");
				write("<body bgcolor=\"#ffffff\" style=\"margin: 0px;\">\n");
				write("<center><img src=\"" + my_imageurl + "\"></center>\n");
				write("</body>\n");
				write("</html>\n");
			}
	newwin.moveTo(window_left,window_top);
	return true;
}

var aktivFeld = "";
function auswahl(art, form) {
	if (aktivFeld != ""){
	  tmpFeld = eval("document.forms[form]." + aktivFeld);
	  tmp = document.selection.createRange();
	  if (tmp.text != "") tmp.text = "#" + art + "start#" + tmp.text + "#" + art + "ende#";
	  aktivFeld = "";
	}
return 1;
}

function checkDate(s_date){
	// returns true if date exists, if not return value is false
	var i_year 	= parseFloat(s_date.substring(6,10));
	var i_month = parseFloat(s_date.substring(3,5));
	var i_day 	= parseFloat(s_date.substring(0,2));
	var daysofeachmonth = new Array(31,28,31,30,31,30,31,31,30,31,30,31);
	//calculate days in february
	daysofeachmonth[1] = (!(i_year % 100) && !(i_year % 400)) ? 28 : (!(i_year % 4) ? 29 : 28);
	if((i_year >=2036 || i_year < 1977) || (i_month < 1 || i_month > 12) || (i_day < 1 || i_day > daysofeachmonth[i_month - 1]))
		return false;
	else
		return true;
}

_editor_url = "";                     // URL to htmlarea files
var win_ie_ver = parseFloat(navigator.appVersion.split("MSIE")[1]);
if (navigator.userAgent.indexOf('Mac')        >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf('Windows CE') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf('Opera')      >= 0) { win_ie_ver = 0; }
if (win_ie_ver >= 5.5) {
  document.write('<scr' + 'ipt src="' +_editor_url+ 'editor.js"');
  document.write(' language="Javascript1.2"></scr' + 'ipt>');  
} else { document.write('<scr'+'ipt>function editor_generate() { return false; }</scr'+'ipt>'); }

var config = new Object(); // create new config object
config.bodyStyle = 'background-color: white; font-family: "Verdana"; font-size: 8pt;';
config.stylesheet = "../css/editorstyles.css";
config.width = "450px";
config.height = "200px";

config.toolbar = [
				  ['bold','italic','underline','separator'],
				  ['strikethrough','subscript','superscript','separator'],
				  ['justifyleft','justifycenter','justifyright','separator'],
				  ['OrderedList','UnOrderedList','Outdent','Indent','separator'],
				  ['forecolor','backcolor','separator'],
				  ['linebreak'],
				  ['HorizontalRule','custom1','custom2']
				];
				
var confignewsletter = new Object(); // create new config object
confignewsletter.bodyStyle = 'background-color: white; font-family: "Verdana"; font-size: 8pt;';
confignewsletter.stylesheet = "../css/editorstyles.css";
confignewsletter.width = "520px";
confignewsletter.height = "260px";

confignewsletter.toolbar = [
				  ['bold','italic','underline','separator'],
				  ['strikethrough','subscript','superscript','separator'],
				  ['justifyleft','justifycenter','justifyright','separator'],
				  ['OrderedList','UnOrderedList','Outdent','Indent','separator'],
				  ['forecolor','backcolor','separator'],
				];
				
