// Function to generate text to create a grey menu for displaying images using HighSlide.
// USAGE: <script language='javascript'>javascript:mnuGrey("Putting on the crampons and harness.");</script>
function mnuGrey(title) {
	document.write("<div class='highslide-caption' id='Click to enlarge'>\n");
	document.write("<div style='height: 84px; background-color: #777777'>\n");
	document.write("<table width='100%' cols='4' border='0'>\n");
	document.write("<tr>\n");
	// Title/caption cell...
	document.write("<td colspan='1' width='52%' align='left' valign='top' style='background-color: #777777'>" + title + "\n");
	document.write("</td>\n");
	// Left arrow cell...
	document.write("<td colspan='1' width='12%' align='right' valign='top' style='background-color: #777777'>\n");
	document.write("<a border='0' href='#' onclick='return hs.previous(this)' class='control'>\n");
	document.write("<img src='/images/system/leftarrow01.gif' />\n");
	document.write("</a>\n");
	document.write("</td>\n");
	// Right arrow cell...
	document.write("<td colspan='1' width='12%' align='left' valign='top' style='background-color: #777777'>\n");
	document.write("<a border='0' href='#' onclick='return hs.next(this)' class='control'>\n");
	document.write("<img src='/images/system/rightarrow01.gif' />\n");
	document.write("</a>\n");
	document.write("</td>\n");
	// Controls (Move, Close) cell...
	document.write("<td colspan='1' width='20%' align='right' valign='top' style='background-color: #777777'>\n");
	document.write("<a href='#' onclick='return hs.close(this)' class='control'>Close</a>\n");
	document.write("<br />\n");
	document.write("<a href='#' onclick='return false' class='highslide-move control'>Move</a>\n");
	document.write("</td>\n");
	document.write("<tr>\n");
	document.write("</table>\n");
	document.write("</div>\n");
	document.write("</div>\n");
}

// Function to generate text to render HTML popup windows using HighSlide.
// USAGE: <script language='javascript'>javascript:htmlpopup('<url>', '<width>', '<height>', '<Text to display in link>');</script>
// eg. <script language='javascript'>javascript:htmlpopup('/manhattan.html', '480', '480', 'atomic bomb');</script>
function htmlpopup(url, width, height, title) {

	var browser = navigator.appName;

	var txt = "<a href='" + url + "' ";
	txt += "onclick=\"return hs.htmlExpand(this, { objectType: 'ajax', contentId: 'highslide-html-8', outlineType: 'rounded-white', outlineWhileAnimating: true, width: '" + width + "', height: '" + height + "' } )\" class='highslide'>";
	txt += title + "</a>";
	if (browser == "Microsoft Internet Explorer"){
		txt += "&nbsp;";
	}
	txt += "<div class='highslide-html-content' id='highslide-html-8' style='padding: 15px; width: auto'>";
	txt += "<div style='height:20px; padding: 5px; border-bottom: 1px solid silver'>";
	txt += "<a href='#' onclick='return hs.close(this)' class='control'>Close</a>";
	txt += "<a href='#' onclick='return false' class='highslide-move control'>Move</a>";
	txt += "</div>";
	txt += "<div class='highslide-body' style='padding: 10px'></div>";
	txt += "<div class='highslide-footer'><hr />";
	txt += "<a href='#' onclick='return hs.close(this)' class='footer-control'>Close</a>";
	txt += "<div>";
	txt += "<span class='highslide-resize' title='ResizeTitle'><span></span></span>";
	txt += "</div></div>";
	txt += "<div style='text-align: center; border-top: 1px solid silver'>";
	txt += "<div><span class='highslide-resize' title='Resize'><span></span></span></div>";
	txt += "</div></div>";

//	var txt = "<a href='" + url + "' onclick=\"return hs.htmlExpand(this, { objectType: 'ajax', contentId: 'highslide-html-8', outlineType: 'rounded-white', outlineWhileAnimating: true, width: '" + width + "', height: '" + height + "' } )\" class='highslide'>" + title + "</a><div class='highslide-html-content' id='highslide-html-8' style='padding: 15px; width: auto'><div style='height:20px; padding: 5px; border-bottom: 1px solid silver'><a href='#' onclick='return hs.close(this)' class='control'>Close</a><a href='#' onclick='return false' class='highslide-move control'>Move</a></div><div class='highslide-body' style='padding: 10px'></div><div class='highslide-footer'><hr /><a href='#' onclick='return hs.close(this)'>Close</a><div><span class='highslide-resize' title='ResizeTitle'><span></span></span></div></div><div style='text-align: center; border-top: 1px solid silver'><div><span class='highslide-resize' title='Resize'><span></span></span></div></div></div>";

	document.write(txt);
}

