/**
 * @author martinjoisten
 */
 
/* Das Suchfeld vergroessern bei Fokus */
function toggleSBSize(big) {
    var sb = document.getElementById('search_news');
    if (big)
        sb.style.width = '25em';
    else
        sb.style.width = '15em';
}

/* Alte Funktion fuer die News */
function openPictureWindow(imageName,imageWidth,imageHeight,alt) {
        newWindow = window.open("","newWindow","width="+imageWidth+",height="+imageHeight);
        newWindow.document.open();
        newWindow.document.write('<HTML><TITLE>'+alt+'</TITLE><meta name="MSSmartTagsPreventParsing" content="TRUE">');
        newWindow.document.write('<meta http-equiv="imagetoolbar" content="no"><BODY bgcolor="#2b2b2b" LEFTMARGIN="0" TOPMARGIN="0" MARGINHEIGHT="0" MARGINWIDTH="0" onBlur="self.close()">');
        newWindow.document.write('<IMG SRC='+imageName+' WIDTH='+imageWidth+' HEIGHT='+imageHeight+' ALT="'+alt+'">');
        newWindow.document.write('</BODY></HTML>');
        newWindow.document.close();
        newWindow.focus();
}

/* col1 in der Hoehe von col3 anzeigen */
function doHeight() {
     var col1 = document.getElementById('col1_content').offsetHeight;
     var col2 = document.getElementById('col2_content').offsetHeight;
	 var col3 = document.getElementById('col3_content').offsetHeight;
	 if(col1 > 10 && col1 < col3) {
		document.getElementById('col1').style['height'] = col3 + 'px';
		document.getElementById('col1_content').style['height'] = col3 + 'px';
/*		document.getElementById('col2').style['height'] = col3 + 'px';
		document.getElementById('col2_content').style['height'] = col3 + 'px';
		*/
	 } else if (col2 > col1 && col2 >= col3) {
		document.getElementById('col1').style['height'] = col2 + 'px';
		document.getElementById('col1_content').style['height'] = col2 + 'px';
	 } 
	 else {
		/*document.getElementById('col2').style['height'] = col1 + 'px';*/
		/*document.getElementById('col2_content').style['height'] = col1 + 'px'; */
	}
}

/* Keine Frames bei der Hauptseite */
/* if(top.frames.length >= 1) top.location.href="/"; */

function showTOP1() {
// <![CDATA[
  if (Element.visible('bfRatgeber')) { } else {
    document.getElementById('bfProdukte').style.display = 'none';
    Effect.SlideDown('bfRatgeber',{duration:1});
  }
// ]]>
}

function showTOP2() {
// <![CDATA[
  if (Element.visible('bfProdukte')) { } else {
    document.getElementById('bfRatgeber').style.display = 'none';
    Effect.SlideDown('bfProdukte',{duration:1});
  }
// ]]>
}
