var prev_id = 0;var last_id = 0;var current_picture_fname = "";var current_picture_width = -1;var current_picture_height = -1;var current_picture_text = "";var activated_picture = 0;	function replace_picture(img_id,fname)	{		var picture = document.getElementById(img_id);		if (picture) {			picture.src = fname;		}	}	function switch_class(id)	{		var cl = document.getElementById("thumb_" + id);		if (cl) {			if (cl.className == "image_select") {				cl.className = "image_deselect";			}			else if (cl.className == "image_deselect") {				cl.className = "image_select";			}		}	}	function set_alt_text(alt)	{		var span_alt = document.getElementById("large_alt");		if (span_alt) {			span_alt.innerHTML = alt;		}	}	function over_picture(id,cur_top,cur_bottom)	{		if ((id) || (id == "0")) {			if (prev_id >= 0) {				switch_class(prev_id);				// replace_picture("cur_top_" + prev_id,"imgs/empty.gif");				replace_picture("cur_bottom_" + prev_id,"imgs/empty.gif");			}			if (cur_top) {				// replace_picture("cur_top_" + id,cur_top);			}			if (cur_bottom) {				replace_picture("cur_bottom_" + id,cur_bottom);			}			prev_id = id;		}	}	function out_picture(cur_top,cur_bottom)	{		return over_picture(last_id,cur_top,cur_bottom);	}	function set_picture(fname,id,cur_top,cur_bottom,img_alt,large_fname,large_w,large_h)	{		replace_picture("large_picture",fname);		if (large_fname != "") {			current_picture_fname  = large_fname;			current_picture_width  = large_w;			current_picture_height = large_h;		}		else {			current_picture_fname = fname;		}		current_picture_text = img_alt;		if ((id) || (id == "0")) {			set_alt_text(img_alt);			switch_class(id);			if (last_id >= 0) {				replace_picture("cur_top_" + last_id,"imgs/empty.gif");			}			if (prev_id >= 0) {				switch_class(prev_id);				// replace_picture("cur_top_" + prev_id,"imgs/empty.gif");				replace_picture("cur_bottom_" + prev_id,"imgs/empty.gif");			}			if (cur_top) {				replace_picture("cur_top_" + id,cur_top);			}			if (cur_bottom) {				replace_picture("cur_bottom_" + id,cur_bottom);			}			prev_id = id;			last_id = id;		}		return 0 == 1;	}	function zoom_picture(fname,w,h)	{		fn = fname;		w2 = w;		h2 = h;		if (current_picture_fname != "") {			fn = current_picture_fname;		}		if (current_picture_width >= 0) {			w2 = current_picture_width;		}		if (current_picture_height >= 0) {			h2 = current_picture_height;		}		url  = "http://www.nashuaone.com/cgi-bin/zoom.cgi";		url += "?image=" + escape(fn);		url += "&width=" + w2;		url += "&height=" + h2;		options  = "toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,copyhistory=no, resizable=no"; 		options += ",width=" + w2;		options += ",height=" + h2;		window.open(url,"_blank",options);		return false;	}