function popup (url, name, scroll, resize, width, height) {
	window.open(url, name,"toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars="+scroll+",resizable="+resize+",width="+width+",height="+height);
}

function rollSetup() {
	var img, hover, norm, down
	for (var i = 0; (img = document.images[i]); i++) {
		if (img.getAttribute) {

			norm = img.getAttribute("src");
			hover = img.getAttribute("hsrc");
			down = img.getAttribute("dsrc");

			if (norm != "" && norm != null) {
				img.n = new Image();
				img.n.src = img.src;
			
				if (hover != "" && hover != null) {
					img.h = new Image();
					img.h.src = hover;
					img.onmouseover = rollSwapOn
					img.onmouseout  = rollSwapOff
				}

				if (down != "" && down != null) {
					img.d = new Image();
					img.d.src = down;
					img.onmousedown = rollSwapDown
				}
			}
		}
	}
}

function rollSwapOn() {
	this.src = this.h.src;
}

function rollSwapOff() {
	this.src  = this.n.src;
}

function rollSwapDown() {
	this.src  = this.d.src;
	this.temp = typeof(document.onmouseup) != 'undefined' && typeof(document.onmouseup) != 'unknown' ? document.onmouseup : "";
	rollSwapUp.img = this;
	document.onmouseup = rollSwapUp;
}

function rollSwapUp() {
	var ths = rollSwapUp.img;
	ths.src = ths.norm.src;
	if (ths.temp) document.onmouseup = ths.temp;
}

