	/**
	 * Function to validate an email-adress
	 */
	function validateEMail(field)
	{
		validRegExp = /^[^@]+@[^@]+.[a-z]{2,}$/i;
		if (field.value.length == 0 || field.value == null || field.value.search(validRegExp) == -1)
			return true;
		else
			return false;
	}


	/**
	 * Function to verify if an input-field, select or textarea has no value
	 */
	function validateIsEmpty(field)
	{
		if (field.value.length == 0 || field.value == null)
			return true;
		else
			return false;
	}

	/**
	 * Function to verify if an input-field, select or textarea has no value, if geschaeftsbericht checked
	 */
	function validateIsEmptyIfChecked(field)
	{
		if (document.kontakt.geschaeftsbericht.checked == true) {
			if (field.value.length == 0 || field.value == null) {
				return true;
			}
		} else {
			return false;
		}
	}

	/**
	 * Function to verify if an radio or checkbox-element has no value
	 */
	function validateIsEmptyRadio(field)
	{
		if (field.value.length == 0 || field.value == null)
			return true;
		else
			return false;
	}


	/**
	 * Function to open PopUp (print-version)
	 */
	 function openPrint(url)
	 {
		var popupX = (screen.width/2)-(650/2);
	    var popupY = (screen.height/2)-(650/2);
	    var pos = "left="+popupX+",top="+popupY;
	    winpops=window.open(url,"","width=650,height=650,scrollbars," +pos)
	 }


	/**
	 * Function to open PopUp (recommend)
	 */
	 function openRecommend(url)
	 {
		var popupX = (screen.width/2)-(650/2);
	    var popupY = (screen.height/2)-(520/2);
	    var pos = "left="+popupX+",top="+popupY;
	    winpops=window.open(url,"","width=650,height=520," +pos)
	 }

	/**
	 * Function to open PopUp (imperia-modul)
	 */
	 function linkPopupOpen(url,w,h)
	 {
		var popupX = (screen.width/2)-(w/2);
	    var popupY = (screen.height/2)-(h/2);
	    var pos = "left="+popupX+",top="+popupY;
	    winpops=window.open(url,"","width="+w+",height="+h+",scrollbars," +pos)
	 }

	/**
	 * Function to open PopUp (imperia-modul)
	 */
	 function linkMultimedia(form, w, h)
	 {
		var popupX	= (screen.width / 2) - (w / 2);
	    var popupY	= (screen.height / 2) - (h / 2);
	    var pos		= "left=" + popupX + ", top=" + popupY;
	    winpops		= window.open('popup.php?name=' + form.name.value + '&firstname=' + form.firstname.value + '&company=' + form.company.value, "", "width=" + w + ", height=" + h + ", scrollbars, " + pos);
	 }

	/**
	 * Bookmark Page
	 */
	function addBookmark(title, url) 
	{
		if (window.sidebar) { 
			  window.sidebar.addPanel(title, url,"");
		} else if( document.all ) {
				window.external.AddFavorite( url, title);
		} else {
			   alert("Sorry, your browser doesn't support this");
		}
	}

	/**
	 * Get Internet explorer Version
	 */
	function getInternetExplorerVersion()
	{
	  var rv = -1; // Return value assumes failure
	  if (navigator.appName == 'Microsoft Internet Explorer')
	  {
		var ua = navigator.userAgent;
		var re  = new RegExp("MSIE ([0-9]{1,}[\.0-9]{0,})");
		if (re.exec(ua) != null)
		  rv = parseFloat( RegExp.$1 );
	  }
	  return rv;
	}


		 