// declarationsvar baseUrl 	= "";var filenames 	= null;var counter 	= 0;function previous() {	go(-1);}function next() {	go(1);}function go(step) {   // declarations   var filename = "";      // modify step   counter += step;   if (counter < 0) {      counter = filenames.length-1;   } else if (counter > filenames.length-1) {      counter = 0;   }      // compose url   filename = baseUrl + filenames[counter];      // get image division   var d = document.getElementById("slideshow_image");   d.innerHTML = "<center><img src=\"" + filename + "\" /></center>";}function startSlideshow(base_url, picture_filenames) {	// store base url	baseUrl = base_url;	if (base_url.substr(base_url.length) != "/") {		baseUrl += "/";	}		// make baseUrl absolute	if (baseUrl.match(/^(http|https|file):\/\/.*/)) {		// url is absolute		baseUrl = baseUrl;	} else {		// add hostname to url		baseUrl = "http://" + document.location.host + baseUrl;	}		// convert filenames to array	filenames = picture_filenames.split("$");		// go to first picture	go(0);}function showSlideshow(doc_url, picture_filenames, headline, summary) {	// show popup	window.open("../Slideshow?ReadForm&url=" + doc_url + "&filenames=" + picture_filenames + "&headline=" + headline + "&summary=" + summary, "hg_slideshow", "width=425,height=575");		// return	return false;}