function changecolorRed(colorid)
{
var colorid;
document.getElementById(colorid).style.color= "#e41b00";
}

function changecolorBlack(colorid)
{
var colorid;
document.getElementById(colorid).style.color= "#000000";
}

function showLoadLayer() {

			document.getElementById("loadingLayer").style.visibility = "hidden";
			document.getElementById("alpah").style.visibility = "hidden";
}

function getSize(){
var x4,y4;
if (parent.self.innerHeight) // all except Explorer
{
	x4 = parent.self.innerWidth;
	y4 = parent.self.innerHeight;
}
else if (parent.document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x4 = parent.document.documentElement.clientWidth;
	y4 = parent.document.documentElement.clientHeight;
}

 
else if (parent.document.body) // other Explorers
{
	x4 = parent.document.body.clientWidth;
	y4 = parent.document.body.clientHeight;
}
var x3,y3;
if (self.innerHeight) // all except Explorer
{
	x3 = self.innerWidth;
	y3 = self.innerHeight;
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x3 = document.documentElement.clientWidth;
	y3 = document.documentElement.clientHeight;
}

 
else if (document.body) // other Explorers
{
	x3 = document.body.clientWidth;
	y3 = document.body.clientHeight;
}

//alert(y4);
//alert(x3);

hs = parent.document.getElementById("win1").style.height;
ws = parent.document.getElementById("win1").style.width;

//// 19 Zoll
if (y4 >= 860) {
///Klein
if (y3 >= 520) {
  parent.document.getElementById("breadcrumb").style.display = "none";

if(document.getElementById("user_content_window_large")) {
  setActiveStyleSheet('w19_min_large');
  }
  
if(document.getElementById("user_content_window_full")) {
  setActiveStyleSheet('w19_min_full');
  }
  
if(document.getElementById("user_content_window_small")) {
  setActiveStyleSheet('w19_min_small');
  }
  
if(document.getElementById("user_content_window_table")) {
  setActiveStyleSheet('w19_min_table');
  }


}
///Gross
if (y3 >= '660') {
if(document.getElementById("user_content_window_large")) {
  setActiveStyleSheet('w19_max_large');
  }
  
if(document.getElementById("user_content_window_full")) {
  setActiveStyleSheet('w19_max_full');
  }
  
if(document.getElementById("user_content_window_small")) {
  setActiveStyleSheet('w19_max_small');
  }
  
if(document.getElementById("user_content_window_table")) {
  setActiveStyleSheet('w19_max_table');
  }
  
  parent.document.getElementById("breadcrumb").style.display = "block";

}
} else {
//// 17 Zoll
//// Klein
parent.document.getElementById("breadcrumb").style.display = "none";
if (y3 >= 440) {
if(document.getElementById("user_content_window_large")) {
  setActiveStyleSheet('w17_min_large');
  }
  
if(document.getElementById("user_content_window_full")) {
  setActiveStyleSheet('w17_min_full');
  }
  
if(document.getElementById("user_content_window_small")) {
  setActiveStyleSheet('w17_min_small');
  }
  
if(document.getElementById("user_content_window_table")) {
  setActiveStyleSheet('w17_min_table');
  }
    
parent.document.getElementById("breadcrumb").style.display = "none";

}
///Gross
if (y3 >= 498) {
if(document.getElementById("user_content_window_large")) {
  setActiveStyleSheet('w17_max_large');
  }
  
if(document.getElementById("user_content_window_full")) {
  setActiveStyleSheet('w17_max_full');
  }
  
if(document.getElementById("user_content_window_small")) {
  setActiveStyleSheet('w17_max_small');
  }

if(document.getElementById("user_content_window_table")) {
  setActiveStyleSheet('w17_max_table');
  }
    
  
parent.document.getElementById("breadcrumb").style.display = "block";
}
}
if (parent.document.getElementById("win1_row1")) {
parent.document.getElementById("title").style.width = x3 +'px';
parent.document.getElementById("win1_row1").style.width = x3 +'px';
}
if(document.getElementById("mainTable")){
document.getElementById("mainTable").style.width = '790px';
}
//alert(document.getElementById("mainTable").style.width);
}


////////////////////////////////////////
//  Fenster für Plattformhinweis      //
////////////////////////////////////////

newwindow=false;
function fenster(url,breite,hoehe) {
  if(newwindow&&newwindow.closed==false)
    newwindow.close()
    var l = (screen.availWidth - breite) / 2;
    var t = (screen.availHeight - hoehe) / 2;
    newwindow = window.open(url,"newwindow","width=" + breite +
                                            ",height=" + hoehe +
                                            ",left=" + l +
                                            ",top=" + t + ",resizable=yes,scrollbars=yes,toolbar=1;"); 
  newwindow.focus();
}



function getHeight(div) {
if (self.innerHeight) // all except Explorer
{
GetHeight = document.getElementById(div).offsetHeight;
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
GetHeight = document.getElementById(div).clientHeight;
} else if (document.body) // other Explorers
{
GetHeight = document.body.clientHeight;
}
return GetHeight;
}

////////////////////////////////////////
//  OnLoad Lorch  / OnResize          //
////////////////////////////////////////

function initPage()
{

document.getElementById("user_navicontent").style.display = "block";
//alert (getHeight("user_navicontent"));
document.getElementById("user_navigation").style.paddingBottom = getHeight("user_navicontent")+34+"px";



document.getElementById("fix_window").style.width = "875px"; 
document.getElementById("fix_window").style.top = "121px";
document.getElementById("fix_window").style.left = "121px";

document.getElementById("fix_window").style.position = "absolute"; 
//document.getElementById("breadcrumb").style.display = "none";
var x1,y1;
if (self.innerHeight) // all except Explorer
{
	x1 = self.innerWidth;
	y1 = self.innerHeight;
y1 = (y1);
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x1 = document.documentElement.clientWidth;
	y1 = document.documentElement.clientHeight;
y1 = (y1);
}

 
else if (document.body) // other Explorers
{
	x1 = document.body.clientWidth;
	y1 = document.body.clientHeight;
y1= (y1);
}


//alert(y1);
//Window Container
if (y1 >= 860) {
//alert(y1);
//alert('gross fix_window');
document.getElementById("fix_window").style.height = "690px";
//document.getElementById("fix_window").style.background = "#000";
} else {
//alert('klein fix_window');
//alert(y1);
document.getElementById("fix_window").style.height = "553px";
//document.getElementById("fix_window").style.background = "#FFF000";
}
}



////////////////////////////////////////
//  Window                            //
////////////////////////////////////////
function openProdWindow(windowid, max) {


if (max) {
//alert("large");
open_win_large(windowid);

} else {
//alert("small");
open_win_small(windowid);
}




}



function open_win_small (windowid) {
mainHeight = document.getElementById("user_main").offsetHeight;
if (mainHeight < 740) {
document.getElementById("user_main").style.height = '750px';
}


//alert(max);
if (document.getElementById("fix_window")) {
document.getElementById("fix_window").style.position = "absolute";
document.getElementById("fix_window").style.width = "846px";
document.getElementById("fix_window").style.left = "132px";
document.getElementById("fix_window").style.right = "0px";
document.getElementById("fix_window").style.display = "inline";
  }
var x2,y2;
if (self.innerHeight) // all except Explorer
{
	x2 = self.innerWidth;
	y2 = self.innerHeight;
y2 = (y2);
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x2 = document.documentElement.clientWidth;
	y2 = document.documentElement.clientHeight;
y2 = (y2);
}

 
else if (document.body) // other Explorers
{
	x2 = document.body.clientWidth;
	y2 = document.body.clientHeight;
y2= (y2);
}
//document.getElementById("user_main").style.display = y2 +"px";
//alert (y2);

query = windowid;
sammlung = new Array();
if (query != '')
{
  query = query.substr(1, query.length - 1);
  query = query.replace(/%26/,'&');
  teile = query.split('&');

  for (i = 0; i < teile.length; i++)
  {
  teile[i] = teile[i].split('=');
  sammlung[teile[i][0]] = teile[i][1];
  }
}
if(sammlung['user_window'] == 1) {


if (y2 >= 860) {
//alert('gross wird geöffnet');
var win = new Window({id: "win1", showEffect:Element.show, hideEffect:Element.hide, className: "alphacube", url: windowid + "&type=1", width:648, height:522, maxWidth:829, maxHeight:660, top:133, left:302, minimizable: false, maximizable: true, parent:('fix_window')}); 
} else {
//alert('klein wird geöffnet');
var win = new Window({id: "win1", showEffect:Element.show, hideEffect:Element.hide, className: "alphacube", url: windowid + "&type=1", width:648, height:440,maxWidth:829, maxHeight:523, top:83, left:302, minimizable: false, maximizable: true, parent:('fix_window')}); 
}

    win.setZIndex(10000);
    win.setDestroyOnClose(); 


    if (y2 >= 860) {
    document.getElementById("alpah").style.width = "648px";

  document.getElementById("alpah").style.height = "552px";
  } else {
  document.getElementById("alpah").style.width = "648px";

  document.getElementById("alpah").style.height = "470px"; 
  }
  
  
  document.getElementById("alpah").style.border = "4px solid #ccc";  
     
    
  win.setConstraint(true);
  win.toFront();
  win.show(); 

} else {
self.location.href = $windowid;
}
}





function open_win_large (windowid) {
mainHeight = document.getElementById("user_main").offsetHeight;
if (mainHeight < 740) {
document.getElementById("user_main").style.height = '750px';
}


//alert(max);
if (document.getElementById("fix_window")) {
document.getElementById("fix_window").style.position = "absolute";
document.getElementById("fix_window").style.width = "846px";
document.getElementById("fix_window").style.left = "131px";
document.getElementById("fix_window").style.right = "0px";
document.getElementById("fix_window").style.display = "inline";
  }
var x2,y2;
if (self.innerHeight) // all except Explorer
{
	x2 = self.innerWidth;
	y2 = self.innerHeight;
y2 = (y2);
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x2 = document.documentElement.clientWidth;
	y2 = document.documentElement.clientHeight;
y2 = (y2);
}

 
else if (document.body) // other Explorers
{
	x2 = document.body.clientWidth;
	y2 = document.body.clientHeight;
y2= (y2);
}
//document.getElementById("user_main").style.display = y2 +"px";
//alert (y2);

query = windowid;
sammlung = new Array();
if (query != '')
{
  query = query.substr(1, query.length - 1);
  query = query.replace(/%26/,'&');
  teile = query.split('&');

  for (i = 0; i < teile.length; i++)
  {
  teile[i] = teile[i].split('=');
  sammlung[teile[i][0]] = teile[i][1];
  }
}
if(sammlung['user_window'] == 1) {




  if (y2 >= 860) {
  //alert('gross wird geöffnet');
  var win = new Window({id: "win1",showEffect:Element.show, hideEffect:Element.hide, className: "alphacube", url: windowid + "&type=1", width:648, height:522, maxWidth:829, maxHeight:660, top:133, left:0, minimizable: false, maximizable: false, parent:('fix_window')}); 
  } else {
  //alert('klein wird geöffnet');
  var win = new Window({id: "win1",showEffect:Element.show, hideEffect:Element.hide, className: "alphacube", url: windowid + "&type=1", width:648, height:440,maxWidth:829, maxHeight:523, top:83, left:0, minimizable: false, maximizable: false, parent:('fix_window')}); 
  }
  
  win.setZIndex(1000);
  win.setDestroyOnClose(); 

  //win.setConstraint(true, {left:11, right:19})


  
  if (y2 >= 860) {
  document.getElementById("alpah").style.width = "829px";
  document.getElementById("alpah").style.height = "690px";
  document.getElementById("border").style.width = "829px";
  } else {
  document.getElementById("alpah").style.width = "829px";
  document.getElementById("alpah").style.height = "553px";
  document.getElementById("border").style.width = "829px";
  }

  
  document.getElementById("alpah").style.border = "4px solid #ccc";  
  win.setConstraint(true);
  win.maximize();
  win.toFront();    
  win.show();   


} else {
self.location.href = $windowid;
}
}

////////////////////////////////////////
//  Window OnLoad                     //
////////////////////////////////////////	

function jumpto () {
//window.location.hash = '#user_product_startpos';	
  }
  
  
function initWinPage()
{


setTimeout("jumpto()",1550);
	
window.document.getElementById("user_navigation_path").style.display = "none";
parent.document.getElementById("win1_top").innerHTML = window.document.getElementById("user_navigation_path").innerHTML;

var x,y,headwidth;

if (document.getElementById("head")){
headwidth = document.getElementById("head").offsetWidth;
document.getElementById("user_content_table_blank_bottom").style.width = headwidth+15+"px";
}

if (self.innerHeight) // all except Explorer
{
	x = self.innerWidth;
	y = self.innerHeight;
y = (y -176);
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x = document.documentElement.clientWidth;
	y = document.documentElement.clientHeight;
y = (y -176);
}

 
else if (document.body) // other Explorers
{
	x = document.body.clientWidth;
	y = document.body.clientHeight;
y= (y -176);
}

}

////////////////////////////////////////
//  Window - OnResize                 //
////////////////////////////////////////
function reloadwin(){
var x,y;
if (self.innerHeight) // all except Explorer
{
	x = self.innerWidth;
	y = self.innerHeight;
y = (y -176);
}
else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x = document.documentElement.clientWidth;
	y = document.documentElement.clientHeight;
y = (y -176);

}
else if (document.body) // other Explorers
{
	x = document.body.clientWidth;
	y = document.body.clientHeight;
y= (y -176);
}

//alert("Aktueller Pfad: " + window.location.hostname + window.location.pathname);
v=location.search.substring(1, location.search.length).split('&');
rest=location.search.substring(1, location.search.length).split(v[3]);
if (rest[1] == undefined) {
rest[1] = "";
}

if (x > 655) {
if (v[3] != "type=2") {
v[3] = "type=2";
window.location = window.location.pathname + "?" + v[0] + "&" + v[1] + "&" + v[2] + "&" + v[3] + rest[1];
}
} else {
if (v[3] != "type=1") {
v[3] = "type=1";
window.location = window.location.pathname + "?" + v[0] + "&" + v[1] + "&" + v[2] + "&" + v[3] + rest[1];
}
}
}