
// asdfasdf
// kjhkjh

function meilaa() {
 var a,b,c,d,e,f,g,h,i
 a='<a href=\"mai'
 b='ari'
 c='\">'
 a+='lto:'
 b+='@'
 e='</a>'
 f=''
 b+='aritikka.'
 b+='com'
 g='<img class="addrpic" style="margin-bottom:-2px;" src=\"'
 h='../pics/address.png'
 i='\" alt="Message."  border="0">'

 if (f) d=f
 else if (h) d=g+h+i
 else d=b

 document.write(a+b+c+d+e)
}


// function to print an id only...
function print_this_id(printpage)
{
var headstr = "<html><head><title></title></head><body>";
var footstr = "</body>";
var oldstr = document.body.innerHTML;
var img = document.getElementById(printpage);
var newstr = img.innerHTML;
document.body.innerHTML = headstr+newstr+footstr;
window.print(); 
document.body.innerHTML = oldstr;
return false;
}

//
//  Background image sould be a full wall fresco, not a painting hanging on the wall...
//
// Credits of Window size part to Boutell.Com, Inc. http://www.boutell.com
//


function rbIsIE()
{
	if (navigator.appName == 'Microsoft Internet Explorer') {
		return true;
	}
	return false;
}

function rbIsOpera()
{
	if (navigator.appName == 'Opera') {
		return true;
	}
	return false;
}

function rbResize()
{
	// We're in "standards mode," so we must use
	// document.documentElement, not document.body, in IE.
	var width = 0;
	var height = 0;
	if (rbIsIE()) {
		// All modern versions of IE, including 7, give the
		// usable page dimensions here.
		width = parseInt(document.documentElement.clientWidth); 	
		height = parseInt(document.documentElement.clientHeight); 	
	} else if (rbIsOpera()) {
		// This is slightly off: the width and height will include
		// scrollbar space we can't really use. Compensate by
		// subtracting 16 pixels of scrollbar space from the width
		// (standard in Opera). Firefox has an equivalent but
		// more serious problem because such a mistake in Firefox
		// will break mouse clicks on the scrollbar in 
		// Mac Firefox (yes, really!). Fortunately, in Firefox,
		// we can use a third method that gives accurate results
		// (see below).
		width = parseInt(window.innerWidth) - 16;
		// If there is a horizontal scrollbar this will be
		// 16 pixels off in Opera. I can live with that.
		// You don't design layouts with
		// horizontal scrollbars, do you? (Shudder)
		height = parseInt(window.innerHeight);
	} else {
		// Other non-IE browsers give the usable page dimensions here.
		// We grab the info by discovering the visible dimensions 
		// of a hidden 100% x 100% div. Opera doesn't like this
		// method any more than IE does. Fun!
		testsize = document.getElementById('rbTestSizeDiv');
		width = testsize.scrollWidth;
		height = testsize.scrollHeight;
	}


	// beware, cascading styles cause random confusion... this is accessing instance, not .css

	img = document.getElementById('rbBackground');

	if ( (height * img.width) > (width * img.height) ) {
		img.style.height = "100%";
		img.style.width = null;
	} else{
		img.style.width = "100%";
		img.style.height = null;
	}

	// If height or width of the screen is less than smallpage, 
	// Sorry about the hardcoding...

	g = document.getElementById('gold');
	if ( height < 470) {
		g.style.top = "265px";
	} else {
		g.style.top= "62%";
	}
	if ( width < 670 ) {
		g.style.left = "380px";
	} else {
		g.style.left = "62%";
	}

}

window.onresize = rbResize;