<!--
function newPopUp( idx, intWidth, intHeight, strGet, strName ) {

	if( ! intHeight ) intWidth = 550;
	if( ! intHeight ) intHeigth = 400;
	if( ! strName ) strName = 'popup' + Math.round( Math.random( ) * 100 );

	var strTarget = "index.php?popup=1&idx=" + idx + "&" + strGet;

	var strParams = "scrollbars=yes, toolbar=no, location=no, directories=no, status=no, menubar=no, resizable=yes, width=" + intWidth + ", height="	+ intHeight;

	win = window.open( strTarget, strName, strParams );

	win.focus();

}

var timerID = null;
var timerRunning = 0;

function doReload( ) {
	timerID = setTimeout( 'document.form2.send.value=0; document.form2.submit( );', 1000 );
	timerRunning = 1;

} // end if


function stopTimer( ) {

	if( timerRunning ) {
		clearTimeout( timerID );
	}

	timerRunning = 0;

}

function setImage( intTplCode, intFieldID, strFile, intWidth, intHeight, intOrgWidth, intOrgHeight ) {

	eval( "document.form2.arrContent_" + intTplCode + "_" + intFieldID + ".value = strFile" );


	temp_img = new Image();
	temp_img.src = strFile;

	eval( "document.images.img_" + intTplCode + "_" + intFieldID + ".src = temp_img.src" );
	eval( "document.images.img_" + intTplCode + "_" + intFieldID + ".width = intWidth" );
	eval( "document.images.img_" + intTplCode + "_" + intFieldID + ".height = intHeight" );


	strValue = 'Größe: ' + intOrgWidth + ' x ' + intOrgHeight + ' Pixel';
	eval( "document.form2.imgsize_" + intTplCode + "_" + intFieldID + ".value = strValue " );

}


function unsetImage( intTplCode, intFieldID ) {

	eval( "document.form2.arrContent_" + intTplCode + "_" + intFieldID + ".value = ''" );

	temp_img = new Image();
	temp_img.src = 'images/gif_trans.gif';

	eval( "document.images.img_" + intTplCode + "_" + intFieldID + ".src = temp_img.src" );
	eval( "document.images.img_" + intTplCode + "_" + intFieldID + ".width = 1" );
	eval( "document.images.img_" + intTplCode + "_" + intFieldID + ".height = 1" );


	eval( "document.form2.imgsize_" + intTplCode + "_" + intFieldID + ".value = ''" );

}


function calculateStrlen( intTplCode, intFieldID, intMax ) {

	eval( "strValue = document.form2.arrContent_" + intTplCode + "_" + intFieldID + ".value " );

	intRest = intMax - strValue.length;

	if( intRest >= 0 ) {
		strOut = intRest + ' Zeichen frei';

	} else {
		strOut =  Math.abs( intRest ) + ' Zeichen zu lang!';

	}

	eval( "document.form2.strlen_" + intTplCode + "_" + intFieldID + ".value = strOut" );



}


function unsetModul( intTplCode, intFieldID ) {

	eval( "document.form2.arrContent_" + intTplCode + "_" + intFieldID + ".value = ''" );
	eval( "document.form2.modname_" + intTplCode + "_" + intFieldID + ".value = ''" );

}



function setModul( intTplCode, intFieldID, intObjID, strObjName ) {

	eval( "document.form2.arrContent_" + intTplCode + "_" + intFieldID + ".value = " + intObjID );
	eval( "document.form2.modname_" + intTplCode + "_" + intFieldID + ".value = '" + strObjName + "'" );

}

//-->
