// Image Functions
// changeImage() and preload() functions for rollovers and GIF animation
// 19990326

// Copyright (C) 1999 Dan Steinman
// Distributed under the terms of the GNU Library General Public License
// Available at http://www.dansteinman.com/dynapi/

var anchoPantalla = screen.width;
var altoPantalla = screen.height;

//var anchoCentro = anchoPantalla / 2

//alert(anchoPantalla);

function preload(imgObj,imgSrc) {
	if (document.images) {
		eval(imgObj+' = new Image()')
		eval(imgObj+'.src = "'+imgSrc+'"')
	}
}
function changeImage(layer,imgName,imgObj) {
	if (document.images) {
		if (document.layers && layer!=null) eval('document.'+layer+'.document.images["'+imgName+'"].src = '+imgObj+'.src')
		else document.images[imgName].src = eval(imgObj+".src")
	}
}

function obrirFotoGran(foto) {
	var finestra = window.open("../images/fotoGran.php?id=" + foto, "foto","scrollbars=YES,status=yes,left=200,top=100");
}

function obrirFelicitacio() {
	var finestra = window.open("images/nadal2009/nadal_09_web.jpg", "felicitacio","scrollbars=YES,status=yes,width=800,height=651,left=200,top=100");
}