// JavaScript Document
function addbookmark()
{
	bookmarkurl="http://www.visiomatic.net/";
	bookmarktitle="visiomatic Home Page - Home Automation In-House Technology";
	if (document.all)
	window.external.AddFavorite(bookmarkurl,bookmarktitle)
}
function Fensterweite()
{
	if (window.innerWidth){
		return window.innerWidth;
	} else if (document.body && document.documentElement.clientWidth){
		return document.documentElement.clientWidth;
	} else {
		return 0;
	}
}
function Fensterhoehe()
{
	if (window.innerHeight){
		return window.innerHeight;
	} else if (document.documentElement.clientHeight){
		return document.documentElement.clientHeight;
	} else if (document.body.clientHeight){
		return document.body.clientHeight;
	} else {
		return 0;
	}
}
function getScrollXY(whichXY) {
	var scrOfX = 0, scrOfY = 0;
	if( typeof( window.pageYOffset ) == 'number' ) {
		//Netscape compliant
		scrOfY = window.pageYOffset;
		scrOfX = window.pageXOffset;
	} else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) {
		//DOM compliant
		scrOfY = document.body.scrollTop;
		scrOfX = document.body.scrollLeft;
	} else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) ) {
		//IE6 standards compliant mode
		scrOfY = document.documentElement.scrollTop;
		scrOfX = document.documentElement.scrollLeft;
	}
	if(whichXY == "x"){
		return scrOfX;
	} else if(whichXY == "y"){
		return scrOfY;
	}
}
function setFooterPos(){
	var footerRef = document.getElementById("footer");
	var teaserRef = document.getElementById("teaserHolder");
	var browserHeight = Fensterhoehe();
	var browserWidth = Fensterweite();
	//var browserWidth = Fensterhoehe();
	browserHeight += getScrollXY("y");
	browserWidth += getScrollXY("x");
	/*footerRef.style.position = "absolute";*/
	footerRef.style.top = browserHeight - 21 + "px";
	teaserRef.style.top = browserHeight - 240 + "px";
	/*teaserRef.style.display = "";*/
	/*footerRef.style.margin = "0 auto 0 auto";
	footerRef.style.width = "960px";*/
	// topTeaserHolder
	var topTeaserRef = document.getElementById("topTeaserHolder");
	if(topTeaserRef != null){
		//alert("topTeaserHolde dksjghf");
		topTeaserRef.style.position = "absolute";
		topTeaserRef.style.left = "0px";
		topTeaserRef.style.top = browserHeight - 262 + "px";
	}
	var topTeasTeRef = document.getElementById("topTeaserTextHolder");
	if(topTeasTeRef != null){
		topTeasTeRef.style.position = "absolute";
		topTeasTeRef.style.left = "0px";
		topTeasTeRef.style.padding = "20px";
		topTeasTeRef.style.top = browserHeight - 372 + "px";
	}
}
//setFooterPos();
//window.onresize = setFooterPos;
//window.onscroll = setFooterPos;