Index: main/trunk/greenstone3/web/WEB-INF/classes/interface_default.properties
===================================================================
--- main/trunk/greenstone3/web/WEB-INF/classes/interface_default.properties	(revision 23809)
+++ main/trunk/greenstone3/web/WEB-INF/classes/interface_default.properties	(revision 23813)
@@ -23,5 +23,5 @@
 ########################
 about.noservices=There are no services available for this collection.
-about.services=Services available:
+about.services=Extra services available:
 about.servicehelp=You can access the services by clicking on the buttons below or on the names on the navigation bar. The navigation bar is persistent across all pages in the collection.
 #about.description=Description:
@@ -54,4 +54,5 @@
 pref.encoding=Encoding:
 pref.hitsperpage=Number of hits per page:
+pref.maxDocs=Maximum documents to return:
 pref.all=all
 pref.set_prefs=Set preferences
@@ -60,5 +61,4 @@
 pref.berrybasket.off=off
 pref.book=Book viewer mode: 
-
 
 ##################
@@ -86,4 +86,125 @@
 external.text=The link you have selected is external to any of your currently selected collections. If you still wish to view this link and your browser has access to the Web, you can {0} to this page; otherwise use your browsers "back" button to return to the previous document.
 external.go_forward=go forward
+
+##################
+# help page
+##################
+help.topicstitle=<h2>Topics</h2>
+
+help.findinginformationtitle=<h2>How to find information in the {0} collection</h2>
+help.findinginformation=There are {0} ways to find information in this collection:
+help.searchdesc=search for particular words that appear in the text by clicking the Search button
+help.browsedesc=browse documents by <i>{0}</i> by clicking the <i>{0}</i> button
+
+help.readingdocstitle=<h2>How to read the documents</h2>
+help.readingdocs=<p>You can tell when you have arrived at an individual book or document because its title, \
+or an image of the front cover, appears at the top left of the page. In some collections, a table of contents appears, \
+while in others (eg. when the paged image option is used) just the page number is shown, along with a box that allows you \
+to select a new page and go forward and backward. In the table of contents, the current section heading is in bold face, \
+and the table is expandable -- click on the folders to open or close them; click on the open book at the top to close it.</p>\
+<p>Underneath is the text of the current section. When you have read through it, there are arrows at the \
+bottom to take you on to the next section or back to the previous one.</p>\
+<p>Below the title or front-cover image are some buttons. Click on <i>EXPAND DOCUMENT</i> to expand out the whole text \
+of the current section, or book. If the document is large, this could take a long time and use a lot of memory! \
+Click on <i>EXPAND CONTENTS</i> to expand out the whole table of contents so that you can see the titles of all \
+chapters and subsections. Click on <i>DETACH PAGE</i> to make a new browser window for this document. \
+(This is useful if you want to compare documents, or read two at once.)</p>
+
+help.openbookshelf=Open this bookshelf
+help.sectionarrows=Go to the previous/next section
+
+help.searchingtitle=<h2>How to search for particular words</h2>
+help.searching=<p>From the search page, you make a query in these simple steps:</p>\
+<ol><li>Specify what items you want to search</li>\
+<li>Say whether you want to search for all or just some of the words</li>\
+<li>Type in the words you want to search for</li>\
+<li>Click the <i>Begin Search</i> button</li>\
+</ol>\
+<p>When you make a query, the titles of twenty matching documents will be shown. \
+There is a button at the end to take you on to the next twenty documents.  From \
+there you will find buttons to take you on to the third twenty or back to the \
+first twenty, and so on.  Click the title of any document, or the little button \
+beside it, to see it.</p>\
+<p>A maximum of 50 is imposed on the number of \
+documents returned.  You can change this number by clicking the \
+<i>PREFERENCES</i> button at the top of the page.</p>
+
+help.querytermstitle=<h3>Search Terms</h3>
+help.queryterms=<p>Whatever you type into the query box is interpreted as a list of words or phrases \
+called "search terms."  A term is a single word containing only letters and digits, or a phrase \
+consisting of a sequence of words enclosed in double quotes ("...").  Terms are separated by white spaces. \
+If any other characters such as punctuation appear, they serve to separate terms just as though they were \
+spaces.  And then they are ignored.  You can't search for words that include punctuation.</p> \
+<p>For example, the query</p> \
+<ul><kbd>Agro-forestry in the Pacific Islands: Systems for Sustainability (1993)</kbd></ul> \
+<p>will be treated the same as</p> \
+<ul><kbd>Agro forestry in the Pacific Islands  Systems for Sustainability  1993 </kbd></ul>
+
+help.querytypetitle=<h3>Query type</h3>
+help.querytype=<p>There are two different kinds of query. </p>\
+<ul>\
+<li>Queries for <b>all</b> of the words.  These look for documents (or chapters, or titles) \
+that contain all the words you have specified. Documents that satisfy the query are displayed, in build order. </li>\
+<li>Queries for <b>some</b> of the words.  Just list some terms that are likely to appear in \
+the documents you are looking for.  Documents are displayed in order of how closely they match the query. \
+When determining the degree of match, </li>\
+<ul> \
+<li> the more search term occurrences a document contains, the closer it matches; </li>\
+<li> terms which are rare in the collection as a whole are more important than common ones; </li>\
+<li> short documents match better than long ones. </li>\
+</ul> \
+</ul> \
+<p>Use as many search terms as you like--a whole sentence, or even a whole paragraph.  If you specify only \
+one term, documents will be ordered by its frequency of occurrence.</p>
+
+help.queryscopetitle=<h3>Scope of queries</h3>
+help.queryscope=<p>In most collections you are given a choice of different indexes to search. For example, there might \
+be author or title indexes. Or there might be chapter or paragraph indexes. Generally, \
+the full matching document is returned regardless of which index you search.</p> \
+<p>If documents are books, they will be opened at the appropriate place.</p>
+
+help.changingpreferencestitle=<h2>Changing your preferences</h2>
+help.changingpreferences=<p>When you click the <i>PREFERENCES</i> button at the top of the page you will \
+be able to change some features of the interface to suit your own requirements.</p>
+
+help.collectionpreferencestitle=<h3>Collection preferences</h3>
+help.collectionpreferences=<p>Some collections comprise several subcollections, which can be searched \
+independently or together, as one unit.  If so, you can select which \
+subcollections to include in your searches on the Preferences page. </p>
+
+help.languagepreferencestitle=<h3>Language preferences</h3>
+help.languagepreferences=<p>Each collection has a default presentation language, but you can switch to \
+a different language if you like.  You can also alter the encoding scheme \
+used by Greenstone for output to the browser -- the software chooses \
+sensible defaults, but with some browsers it may be necessary to switch to \
+a different encoding scheme to ensure correct character display. \
+All collections allow you to switch from the standard graphical interface format to a textual one. This \
+is particularly useful for visually impaired users who use large screen fonts or speech synthesizers for output.</p>
+
+help.presentationpreferencestitle=<h3>Presentation preferences</h3>
+help.presentationpreferences=<p>Depending on the particular collection, \
+there may be several options you can set that control the presentation. </p> \
+<p>Collections of Web pages allow you to suppress the Greenstone navigation bar at the top of each document page, \
+so that once you have done a search you land at the exact Web page that matches without any Greenstone header. \
+To do another search you will have to use your browser's "back" button. These collections also allow you to suppress \
+Greenstone's warning message when you click a link that takes you out of the digital library collection and on to the \
+Web itself. And in some Web collections you can control whether the links on the search results page take you straight \
+to the actual URL in question, rather than to the digital library's copy of the page. </p>
+
+help.searchpreferencestitle=<h2>Search preferences</h2>
+help.searchpreferences1=<p>You can switch to an "advanced" query mode which allows you to combine terms \
+using &amp; (for "and"), | (for "or"), and ! (for "not"), using parentheses for \
+grouping if desired. This allows you to specify more precise queries. </p>\
+<p>It is possible to get a large query box, so that you can easily do paragraph-sized searching. \
+It is surprisingly quick to search for large amounts of text. </p>\
+
+help.searchpreferences2=<p>You can turn on the search history feature, which shows you your last few \
+queries.  This makes it easy to repeat slightly modified versions of previous queries.</p> \
+<p>Finally, you can control the number of hits returned, and the \
+number presented on each screenful.</p>
+
+help.mgsearchpreferences=<p>A pair of buttons controls whether upper and lower case must match when searching. \
+For example, if "ignore case differences" is selected, snail farming will be treated the same as Snail Farming and SNAIL FARMING. </p>
+
 ##################
 # authentication page
Index: main/trunk/greenstone3/web/interfaces/oran/js/berrybasket.js
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/js/berrybasket.js	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/js/berrybasket.js	(revision 23813)
@@ -59,5 +59,5 @@
 		// they are set to be invisible to prevent flickering when first loaded (see berry.css)
 
-		var berries = $('img');
+		var berries = document.getElementsByTagName('img');
 		var berrybasket = new YAHOO.util.DDTarget('berrybasket','basket');
 
@@ -87,4 +87,5 @@
 
 	var responseFailure = function(o){
+		alert("CHECKOUT FAILED");
 //alert( arguments.callee );
 	}
@@ -165,12 +166,8 @@
 	var basketHandle = YAHOO.util.Dom.get('baskethandle');
 	var berries = YAHOO.util.Dom.get('berries');
-	var div = document.createElement('div');
-	var list = document.createElement('ol');
 	var width = 500;
 	var height = 40;
 	var i=0;
 
-	list.id = 'doclist';
-
 	//remove berryImages in the berry basket
 	while (berries.hasChildNodes()) {
@@ -180,12 +177,20 @@
 		basketHandle.removeChild(basketHandle.firstChild);
 	}
+	
+	var div = document.createElement('div');
+	berries.appendChild(div);
+	var list = document.createElement('ol');
+	div.appendChild(list);
+	
+	list.id = 'doclist';
 
 	//put the berries in
-	for (i in berryList){
+	for (i; i < berryList.length; i++){
 		var berryItem = berryList[i];
 		var berryElement = document.createElement('li');
+		list.appendChild(berryElement);
 		var title = berryItem.getAttribute('title');
 		var root_title = berryItem.getAttribute('root_title');
-		var id = berryItem.getAttribute('collection')+":"+berryItem.getAttribute('name');
+		//var id = berryItem.getAttribute('collection')+":"+berryItem.getAttribute('name');
 
 		if (root_title != ""){
@@ -197,9 +202,9 @@
 			title = title.substring(0,20)+" ... "+title.substr(title.length-35,35);
 		}
-
-		berryElement.appendChild(document.createTextNode(title));
+		
 		berryElement.setAttribute("class","berryitem");
-		list.appendChild(berryElement);
-		height +=18;
+		berryElement.setAttribute("title",title);
+		berryElement.innerHTML = title;
+		height +=40;
 	}
 
@@ -207,20 +212,32 @@
 	oldWidth = berryBasket.style.width;
 	oldBg = berryBasket.style.background;
-	berryBasket.style.height = height;
-	berryBasket.style.width = width;
+	//berryBasket.style.height = height;
+	//berryBasket.style.width = width;
 	berryBasket.style.background ='url("interfaces/default/images/kete2.png") 0 0 repeat';
 	berryBasket.style.cursor = "default";
 	berryBasket.className = "show";
-	div.appendChild(list);
-	berries.appendChild(div);
-	berries.style.height = height - 40;
+	//berries.style.height = height - 40;
 
 	//put the full view link in
 	var fullView = document.createElement('a');
 	berries.appendChild(fullView);
+	
+	//Find the collection in the cgi parameters
+	var url = window.location.href;
+	var colstart = url.indexOf("&c=");
+	var collectionName = "";
+	if (colstart != -1)
+	{
+		var colend = url.indexOf("&", (colstart + 1));
+		if (colend == -1)
+		{
+			colend = url.length - 1;
+		}
+		collectionName = url.substring(colstart + 3, colend);
+	}
+	
 	fullView.appendChild(document.createTextNode('Full View Â»'));
-	fullView.setAttribute("href","?a=g&sa=berry&c=&s=DisplayList&rt=r");
+	fullView.setAttribute("href","?a=g&sa=berry&c=&s=DisplayList&rt=r&p.c=" + collectionName);
 	fullView.setAttribute("id","berryFullViewLink");
-
 
 	//toggle expand/collapse links
Index: main/trunk/greenstone3/web/interfaces/oran/js/berrycheckout.js
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/js/berrycheckout.js	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/js/berrycheckout.js	(revision 23813)
@@ -15,6 +15,6 @@
 
 function navigate(e){
-
-	var target = e.target;
+	
+	var target = this;
 
 	if ( target.id.toLowerCase() == '' ) {
@@ -46,4 +46,7 @@
 		var parea =YAHOO.util.Dom.get('pretextarea');
 		urlonly = false;
+		
+		this.value='URL only view';
+		
 		populateUrlsAndMetadata(parea);
 		return;
@@ -56,4 +59,7 @@
 		populateUrls(parea);
 		urlonly = true;
+		
+		this.value='URL and Metadata view';
+		
 		return;
 	}
@@ -91,4 +97,14 @@
 }
 
+function pageLoad(){
+	for(var j = 0; j < options.length; j++)
+	{
+		var ele = document.getElementById(options[j]);
+		YAHOO.util.Event.addListener(ele, 'click', navigate);
+	}
+	
+	showFullView();
+}
+
 function showFullView(){
 
@@ -101,5 +117,4 @@
 		return;
 	}
-
 
 	var trashbin = document.createElement('div');
@@ -277,7 +292,7 @@
 	input.setAttribute("value", "send");
 	content.appendChild(input);
-
-}
-
+	
+	YAHOO.util.Event.addListener(input, 'click', navigate);
+}
 
 function buildPreview(parent){
@@ -285,6 +300,18 @@
 	var div = document.createElement('div');
 	var cb = document.createElement('input');
-	cb.type = 'checkbox';
-
+	cb.setAttribute('class', 'sendbutton');
+	cb.type = 'button';
+	cb.id = 'urlcheck';
+	if (urlonly)
+	{
+		cb.value='URL and Metadata view';
+	}
+	else
+	{
+		cb.value='URL only view';
+	}
+
+	YAHOO.util.Event.addListener(cb, 'click', navigate);
+	
 	var img = document.createElement('img');
 	img.src = 'interfaces/default/images/check3.gif';
@@ -296,5 +323,5 @@
 	urls.id = 'urls';
 	urls.className = 'berrycheck';
-	urls.appendChild(document.createTextNode('URL only'));
+	//urls.appendChild(document.createTextNode('URL only'));
 	div.appendChild(urls);
 
@@ -312,7 +339,12 @@
 	parent.appendChild(parea);
 
-	populateUrlsAndMetadata(parea);
-
-
+	if(urlonly)
+	{
+		populateUrls(parea);
+	}
+	else
+	{
+		populateUrlsAndMetadata(parea);
+	}
 }
 
@@ -406,6 +438,5 @@
 }
 
-YAHOO.util.Event.addListener(window,'click', navigate);
-YAHOO.util.Event.addListener(window,'load', showFullView);
-
-
+YAHOO.util.Event.addListener(window,'load', pageLoad);
+
+
Index: main/trunk/greenstone3/web/interfaces/oran/style/berry.css
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/style/berry.css	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/style/berry.css	(revision 23813)
@@ -39,5 +39,5 @@
 	display:block;
 	cursor: pointer;
-	text-align: right;
+	text-align: left;
 	padding: .5em;
 }
@@ -142,5 +142,5 @@
    font-weight: bold;
    cursor: pointer;
-   width: 5em;
+   /*width: 5em;*/
    font-size: 90%;
    margin: 1em 0 0 0;
Index: main/trunk/greenstone3/web/interfaces/oran/style/core.css
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/style/core.css	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/style/core.css	(revision 23813)
@@ -17,26 +17,13 @@
 	padding: 0;
 	line-height: 160%;
-/*	background: url('../images/layout/containerLeft.png') scroll repeat-y left top;*/
 	background-color: #fff;
 	border: 1px solid #c8c3b9;
 }
-#container2 {
-	/* background: url('../images/layout/containerRight.png') scroll repeat-y right top; */
-}
-/*
-#container3 {
-	background: url('../images/layout/containerTop.png') scroll repeat-x left top;
-}
-#container4 {
-	background: url('../images/layout/containerBottom.png') scroll repeat-x left bottom;
-	padding: 10px;
-}
-*/
 
 #gs_banner {
-	background: transparent url('../images/gsdlhead.gif') scroll no-repeat left top;
+	/*background: transparent url('../images/gsdlhead.gif') scroll no-repeat left top;*/
+	background-color: #008800;
 	padding: 10px 20px 30px 20px;
 	min-height: 80px;
-	max-height: 110px;
 	position: relative;
 }
@@ -108,45 +95,81 @@
 body.dAction #gs_banner h2 {
 	max-width: 600px;
-	font-size: 100%;
+	font-size: 100;
+}
+
+#titlearea {
+	padding-left: 1em;
+	padding-right: 1em;
+	height:60px;
+	background-color: #007200;
+	width:40%;
+}
+
+#titlesearchcontainer {
+	width:100%;
+	margin: 5px 0 5px;
+}
+
+#quicksearcharea {
+	width:60%;
+	text-align:right;
+	padding: 5px;
+	color:white;
+	background-color:#007200;
+}
+
+#quicksearcharea table{
+	font-size:10px; 
+	margin:0; 
+	float: right;
+}
+
+#quicksearcharea a{
+	font-size: 11px;
+	color:white; 
+	text-transform:lowercase;
+	padding-left:10px; 
+}
+
+#expandqueryboxbutton {
+	color:white;
+	text-decoration:none;
 }
 
 #breadcrumbs {
-	margin: 0 0 10px 0;
-	height: 30px;
-	line-height: 30px;
-}
-#gs_banner h2 {
-	margin: 0 0 10px 1em;
-}
-
+	/*margin: 0 0 10px 0;*/
+	height: 25px;
+	line-height: 15px;
+}
 
 /* css to make the tabs work */
 #nav {
-	position: absolute;
+	position:absolute;
 	width: auto;
 	bottom: 0;
-	right: 0;
+	left: 0;
 	list-style: none;
 	margin:0;
-	padding: 0 15px 0 0;
+	padding: 0 0 0 20px;
 	font-size: 14px;
 }
 
 #nav li {
-	float: right;
+	float: left;
 	color: #fff;
 	background: transparent url('../images/tab-right.png') scroll no-repeat 100% -100px;
 	margin: 0 5px 0 0;
 	padding: 0 8px 0 0;
+	text-transform: capitalize;
 }
 
 #nav a {
+
 	display: block;
-	float: left;
-
+	float:left;
 	background: transparent url('../images/tab-left.png') no-repeat scroll 0 -100px;
 	margin:0;
 	padding: 5px 4px 3px 10px;
-	font-weight: normal;
+	font-weight: bold;
 	color: #fff;
 	text-decoration: none;
@@ -164,5 +187,5 @@
 	list-style: none;
 	margin:0;
-	top: 15px;
+	top: 7px;
 	right: 0;
 	padding: 0 15px 0 0;
Index: main/trunk/greenstone3/web/interfaces/oran/transform/layouts/main.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/layouts/main.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/layouts/main.xsl	(revision 23813)
@@ -15,4 +15,7 @@
 	exclude-result-prefixes="util java util">
 
+	<xsl:include href="header.xsl"/>
+	<!--<xsl:include href="formatmanager.xsl"/>-->
+	
 	<xsl:include href="xml-to-gui.xsl"/>
 	<xsl:include href="xml-to-gui-templates.xsl"/>
@@ -33,15 +36,6 @@
 
 			<head>
-				<title><xsl:call-template name="pageTitle"/> :: <xsl:call-template name="siteName"/></title>
-				<link rel="stylesheet" href="interfaces/{$interface_name}/style/core.css" type="text/css"/>
-				<!-- <script type="text/javascript" src="interfaces/oran/js/jquery.js"><xsl:text> </xsl:text></script> --> 
-                <script type="text/javascript" src="interfaces/oran/js/jquery-1.4.2.js"><xsl:text> </xsl:text></script>
-                <!-- <script type="text/javascript" src="interfaces/oran/js/jquery-ui-1.8.2.custom.min.js"><xsl:text> </xsl:text></script> -->
-                <script type="text/javascript" src="interfaces/oran/js/jquery-ui-1.8rc1/ui/jquery-ui.js"><xsl:text> </xsl:text></script>
-                <script type="text/javascript" src="interfaces/oran/js/jquery.selectboxes.js"><xsl:text> </xsl:text></script>
-                <!-- <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.5/jquery-ui.js"><xsl:text> </xsl:text></script> -->
-                <!-- <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.2.min.js"><xsl:text> </xsl:text></script> -->
-                <!-- <script type="text/javascript" src="interfaces/oran/js/jquery-ui-1.8rc1/jquery-1.4.1.js"><xsl:text> </xsl:text></script> -->
-
+				<!-- ***** in header.xsl ***** -->
+				<xsl:call-template name="create-html-header"/>
 				<xsl:call-template name="berryBasketHeadTags"/>
 			</head>
@@ -51,206 +45,15 @@
 				<xsl:call-template name="displayErrorsIfAny"/>
 
-				<div id="container"><div id="container2"><div id="container3"><div id="container4">
+				<div id="container">
 
 					<div id="gs_banner">
 
-						<!-- show the title -->
-						<div id="breadcrumbs"><xsl:call-template name="breadcrumbs"/><xsl:text> </xsl:text></div>
-						<h2><xsl:call-template name="pageTitle"/></h2>
-
-						<xsl:if test="/page/pageResponse/collection">
-							<!-- show home, help, preferences links -->
-							<ul id="bannerLinks">
-
-								<!-- preferences -->
-								<li>
-									<a href="{$library_name}?a=p&amp;amp;sa=pref&amp;amp;c={$collName}">
-										<xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_tip')"/></xsl:attribute>
-										<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
-									</a>
-								</li>
-
-								<!-- help -->
-								<li>
-									<a href="{$library_name}?a=p&amp;amp;sa=help&amp;amp;c={$collName}">
-										<xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_tip')"/></xsl:attribute>
-										<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
-									</a>
-								</li>
-
-								<li>
-									<a href="{$library_name}?a=p&amp;amp;sa=home">
-										<xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_tip')"/></xsl:attribute>
-										<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/>
-									</a>
-								</li>
-
-							</ul>
-						</xsl:if>
-
-						<!-- show the available 'services' (browse, search, etc.) -->
-						<xsl:if test="/page/pageResponse/collection/serviceList/service">
-							<ul id="nav">
-								<!-- show browse service, if it exists -->
-								<xsl:if test="/page/pageResponse/collection/serviceList/service[@type='browse']">
-									<xsl:for-each select="/page/pageResponse/collection/serviceList/service[@type='browse']">
-										<xsl:call-template name="navigationTab"/>
-									</xsl:for-each>
-								</xsl:if>
-
-								<!-- show search services (collapsed) if they exist -->
-								<xsl:if test="/page/pageResponse/collection/serviceList/service[@type='query']">
-									<xsl:for-each select="/page/pageResponse/collection/serviceList">
-
-										<!--
-											using collapsedNavigationTab instead of navigationTab collapses
-											all the services of the given type onto one tab
-										-->
-										<xsl:call-template name="collapsedNavigationTab">
-											<xsl:with-param name="type">query</xsl:with-param>
-										</xsl:call-template>
-									</xsl:for-each>
-								</xsl:if>
-
-								<!-- all other services -->
-								<xsl:for-each select="/page/pageResponse/collection/serviceList/service[not(@type='query') and not(@type='browse')]">
-									<xsl:call-template name="navigationTab"/>
-								</xsl:for-each>
-
-							</ul>
-						</xsl:if>
+						<!-- ***** in header.xsl ***** -->
+						<xsl:call-template name="create-banner"/>
 
 					</div>
+					
+					<!--<xsl:call-template name="formatmanagerpre"/>-->
 
-<!-- *************************************************************************************** -->
-
-    <!-- <xsl:variable name="foo"> -->
-    <!-- <xsl:value-of select="/page/pageRequest/paramList[@name='formatedit']"/> -->
-
-    <xsl:if test="/page/pageRequest/paramList/param[(@name='formatedit') and (@value='1')]">
-
-<!-- Sam2's div code -->
-
-    <script type="text/javascript" src="interfaces/oran/js/innerxhtml.js"><xsl:text> </xsl:text></script>
-    <script type="text/javascript" src="interfaces/oran/js/gui_div.js"><xsl:text> </xsl:text></script>
-   
-    <xsl:call-template name="xml-to-gui-templates">
-        <xsl:with-param name="node-set" select="test"/>
-        <xsl:with-param name="metadataSets" select="//metadataSetList"/>
-    </xsl:call-template>
-
-    <xsl:variable name="fmt1">
-        <xsl:call-template name="xml-to-string">
-            <xsl:with-param name="node-set" select="//format[@type='browse']"/>
-          </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:variable name="meta">
-        <xsl:call-template name="xml-to-string">
-            <xsl:with-param name="node-set" select="//metadataSetList"/>
-          </xsl:call-template>
-    </xsl:variable>
-
-    <style type="text/css">
-        .placeholder{margin-left: 10px; border: dashed 1px #ccc; background-color:#FFFFCC; height:20px; }
-
-        .placeholder_td{margin-left: 10px; border: dashed 1px #ccc; background-color:#FFFFCC; width:20px; }
-
-        .header { background-color: #AFCCAF; border: solid 1px #117711; padding: 5px; padding-left: 10px;}
-
-        .resizable { width: 150px; height: 150px; padding: 0.5em; } 
-        
-        .block { margin-left: 15px; border-left: dashed 1px black;}
-
-        .droppable { background-color: #99dd99;}
-        .droppable_hl { border: dashed 1px #ccc; background-color:#FFFFCC; }
-
-        <!-- .gsf_metadata { border: solid 2px #0000BB; background-color: #440077; } -->
-
-        <!-- .gsf_choose_metadata { border: solid 1px #000000; background-color: #223344; } -->
-    </style>
-
-    <link rel="stylesheet" type="text/css" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.1/themes/base/jquery-ui.css"/> 
-
-    <table width="100%" border="1"> 
-
-    <td width="75%">
-
-    <button id="updateFormatStatement" type="button" onclick="updateFormatStatement()">Update Format Statement</button>
-    <button id="saveFormatStatement" type="button" onclick="saveFormatStatement()">Save Format Statement</button>
-
-    <div id="formatStatement">
-        <div id="formatRoot">
-    
-    <xsl:call-template name="xml-to-gui">
-        <xsl:with-param name="node-set" select="//format"/> <!-- [@type='browse']"/>  -->
-        <xsl:with-param name="metadataSets" select="//metadataSetList"/> 
-    </xsl:call-template> 
-        </div>
-    </div>
-    </td>    
-
-
-    <td width="25%" valign="top">
-        <h2> Elements to add </h2>
-        <!-- <div class="header element_type_gsf_template css_gsf_template" title="gsf:template">TEMPLATE</div> -->
-        <div class="draggable_gsf_template css_gsf_template block" title="gsf:template"><table class="header"><tbody><tr><td class="header">MATCH=<input type="text" name="rawtextinput" size="10"/></td><td><a href="#" class="minmax ui-icon ui-icon-minusthick">[-]</a></td><td><a href="#" class="remove ui-icon ui-icon-closethick">[x]</a></td></tr></tbody></table><table border="1"><tr class="tr"><td class="droppable" width="10px"></td></tr></table></div><br/>
-
-        <div class="draggable_gsf_choose_metadata css_gsf_choose_metadata block" title="gsf:choose-metadata"><table class="header"><tbody><tr><td class="header">CHOOSE</td><td class="header"><a href="#" class="minmax ui-icon ui-icon-minusthick" title="Click me to expand">[-]</a></td><td class="header"><a href="#" class="remove ui-icon ui-icon-closethick" title="Click me to remove"/></td></tr></tbody></table></div>
-
-        <div class="draggable_gsf_metadata css_gsf_metadata block" title="gsf:metadata"><table class="header"><tbody><tr><td class="header"><xsl:call-template name="meta-to-combo">
-                        <xsl:with-param name="metadataSets" select="//metadataSetList"/>
-                        <xsl:with-param name="current" select="ex.Title"/>
-                     </xsl:call-template></td><td class="header"><a href="#" class="remove ui-icon ui-icon-closethick" title="Click me to remove"/></td></tr></tbody></table></div>
-
-        <div class="draggable_gsf_link css_gsf_link block" title="gsf:link"><table class="header"><tbody><tr><td class="header">LINK<select>
-                            <option value = "document" selected = "document">Document</option>
-                            <option value = "classifier">Classifier</option>
-                            <option value = "source">Source</option>
-                            <option value = "horizontal">Horizontal</option>
-                </select></td><td><a href="#" class="minmax ui-icon ui-icon-minusthick">[-]</a></td><td><a href="#" class="remove ui-icon ui-icon-closethick">[x]</a></td></tr></tbody></table></div>
-
-        <div class="draggable_gsf_switch css_gsf_switch block" title="gsf:switch"><table class="header"><tbody><tr><td class="header">SWITCH</td><td><a href="#" class="minmax ui-icon ui-icon-minusthick">[-]</a></td><td><a href="#" class="remove ui-icon ui-icon-closethick">[x]</a></td></tr></tbody></table></div>
-
-        <div class="draggable_gsf_when css_gsf_when block" title="gsf:when"><table class="header"><tbody><tr><td class="header">WHEN<xsl:value-of select="@test"/></td><td class="header"><a href="#" class="minmax ui-icon ui-icon-minusthick">[-]</a></td><td class="header"><a href="[myhref]" class="ui-icon ui-icon-closethick"/></td></tr></tbody></table></div>
-
-        <div class="draggable_gsf_otherwise css_gsf_otherwise block" title="gsf:otherwise"><table class="header"><tbody><tr><td class="header">OTHERWISE</td><td class="header"><a href="#" class="minmax ui-icon ui-icon-minusthick">[-]</a></td><td><a href="#" class="ui-icon ui-icon-closethick"/></td></tr></tbody></table></div>
-
-        <div class="draggable_gsf_icon css_gsf_icon block" title="gsf:icon"><table class="header"><tbody><tr><td class="header">ICON<select><option value = "document" selected = "document">Document</option><option value = "classifier">Classifier</option><option value = "source">Source</option></select></td><td><a href="#" class="remove ui-icon ui-icon-closethick">[x]</a></td></tr></tbody></table></div>
-        <br/>
-        <div class="draggable_gsf_text css_text" title="text"><table class="header"><tbody><tr><td class="header"><input type="text" name="rawtextinput" size="10" value=""/></td><td class="header"><a href="[myhref]" class="ui-icon ui-icon-closethick"/></td></tr></tbody></table></div>
-        <div class="draggable_table css_table" title="gsf:table">NEW TABLE</div>
-        <div class="draggable_tr css_tr" title="gsf:row">NEW TABLE ROW</div>
-        <div class="draggable_td css_td" title="gsf:column">NEW TABLE COLUMN</div>
-
-    </td>
-    </table>
-
-    <!--
-    <div id="format">
-        <p>
-          <b>Format string here</b>
-          <i>
-              <xsl:value-of select="$fmt1"/>
-          </i>
-        </p>
-    </div> -->
-    <!--    <p>
-          <i>
-              <xsl:value-of select="$meta"/>
-          </i>
-        </p>
-      </div> -->
-      </xsl:if>
-
-<!-- *************************************************************************************** -->
-<!--<H2>Preview</H2>
-
-                    <div id="my_categories"><xsl:text> </xsl:text></div>
-
-                    <iframe name="preview" id="iframe" width="98%" height="300">Your browser does not support iframes</iframe> 
-
-                    <xsl:variable name="preview"> -->
-                    <!-- <button type="button" onclick="loadXMLDoc()">Change Content</button> -->
 					<div id="gs_content">
 						<!--
@@ -261,13 +64,6 @@
 
 					</div>
-   <!--                 </xsl:variable>
-
-                    <script type="text/javascript">
-                        preview_html = <xsl:text disable-output-escaping="yes">'</xsl:text><xsl:copy-of select="$preview"/><xsl:text disable-output-escaping="yes">';</xsl:text>
-                    </script>
-
-                    <div id="result">
-                    Here
-                    </div>-->
+					
+					<!--<xsl:call-template name="formatmanagerpost"/>-->
 
 					<div id="gs_footer">
@@ -280,10 +76,9 @@
 					<div class="corner" id="cornerBottomRight"><xsl:text> </xsl:text></div>
 
-				</div></div></div></div>
+				</div>
 
 			</body>
 		</html>
 	</xsl:template>
-
 </xsl:stylesheet>
 
Index: main/trunk/greenstone3/web/interfaces/oran/transform/pages/berry.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/pages/berry.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/pages/berry.xsl	(revision 23813)
@@ -10,10 +10,10 @@
 	<!-- use the 'main' layout -->
 	<xsl:include href="layouts/main.xsl"/>
-
+	
 	<!-- set page title -->
 	<xsl:template name="pageTitle"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref.berrybasket')"/></xsl:template>
 
 	<!-- set page breadcrumbs -->
-	<xsl:template name="breadcrumbs"><gslib:siteLink/><gslib:rightArrow/></xsl:template>
+	<xsl:template name="breadcrumbs"><gslib:siteLink/><gslib:rightArrow/> <gslib:collectionNameLinked/><gslib:rightArrow/></xsl:template>
 
 	<!-- the page content -->
@@ -24,16 +24,16 @@
 			var doc;
 			var docList = new Array();
-			<xsl:for-each select="/page/pageResponse/collection/item">
-				<xsl:text disable-output-escaping="yes">
-			doc = new Array();</xsl:text>
+			<xsl:for-each select="/page/pageResponse/berryList/item">
+				<xsl:text disable-output-escaping="yes">doc = new Array();</xsl:text>
 				<xsl:for-each select="@*">
-					<xsl:text disable-output-escaping="yes">
-			doc["</xsl:text><xsl:value-of select="name()" /><xsl:text disable-output-escaping="yes">"]='</xsl:text><xsl:value-of select="." /><xsl:text disable-output-escaping="yes">';</xsl:text>
+					<xsl:text disable-output-escaping="yes">doc["</xsl:text>
+					<xsl:value-of select="name()" />
+					<xsl:text disable-output-escaping="yes">"]='</xsl:text>
+					<xsl:value-of select="." />
+					<xsl:text disable-output-escaping="yes">';</xsl:text>
 				</xsl:for-each>
-				<xsl:text disable-output-escaping="yes">
-			docList[</xsl:text>
+				<xsl:text disable-output-escaping="yes">docList[</xsl:text>
 				<xsl:value-of select="position()-1"/>
-				<xsl:text>] = doc;
-</xsl:text>
+				<xsl:text>] = doc;</xsl:text>
 			</xsl:for-each>
 		</script>
Index: main/trunk/greenstone3/web/interfaces/oran/transform/pages/classifier.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/pages/classifier.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/pages/classifier.xsl	(revision 23813)
@@ -21,5 +21,5 @@
 
 		<!-- show the classifiers if more than one (title, subject, etc.) -->
-		<xsl:if test="service/classifierList/classifier[2]">
+		<!--<xsl:if test="service/classifierList/classifier[2]">
 			<div id="classifierList" class="navList">
 				<ul>
@@ -30,12 +30,14 @@
 				<div class="clear"><xsl:text> </xsl:text></div>
 			</div>
-		</xsl:if>
+		</xsl:if>-->
 
 		<!-- this right sidebar -->
-		<div id="rightSidebar">
-			<!-- show the berry basket if it's turned on -->
-			<gslib:berryBasket/>
-			<xsl:text> </xsl:text>
-		</div>
+		<xsl:if test="$berryBasketOn">
+			<div id="rightSidebar">
+				<!-- show the berry basket if it's turned on -->
+				<gslib:berryBasket/>
+				<xsl:text> </xsl:text>
+			</div>
+		</xsl:if>
 	
 		<!--
Index: main/trunk/greenstone3/web/interfaces/oran/transform/pages/document.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/pages/document.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/pages/document.xsl	(revision 23813)
@@ -19,5 +19,17 @@
 
 	<!-- set page breadcrumbs -->
-	<xsl:template name="breadcrumbs"><gslib:siteLink/><gslib:rightArrow/></xsl:template>
+	<xsl:template name="breadcrumbs">
+		<gslib:siteLink/><gslib:rightArrow/> 
+		<gslib:collectionNameLinked/><gslib:rightArrow/> 
+		<a>
+			<xsl:attribute name="href">
+				<xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="$collName"/>&amp;d=<xsl:value-of select="/page/pageResponse/document/documentNode[1]/@nodeID"/>&amp;dt=<xsl:value-of select="/page/pageResponse/document/documentNode/@docType"/>&amp;p.a=b&amp;p.s=<xsl:value-of select="/page/pageResponse/service/@name"/>
+			</xsl:attribute>
+			<xsl:variable name="documentTitleVar">
+				<gslib:documentTitle/>
+			</xsl:variable>
+			Document
+		</a>
+	</xsl:template>
 
 	<!-- the page content -->
@@ -45,6 +57,5 @@
 
 		<!-- display the document -->
-                <xsl:choose>
-
+		<xsl:choose>
 			<xsl:when test="@external != ''">
 				<xsl:call-template name="externalPage">
@@ -132,12 +143,18 @@
 
 	</xsl:template>
-  <xsl:template name="externalPage">
-    <xsl:param name="external"/>
-    <xsl:variable name="go_forward_link"><a><xsl:attribute name="href"><xsl:value-of select="$external"/></xsl:attribute><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'external.go_forward')"/></a></xsl:variable>
-    <h2><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'external.title')"/></h2>
-    <p><xsl:value-of select="util:getInterfaceTextWithDOM($interface_name, /page/@lang, 'external.text', $go_forward_link)" disable-output-escaping="yes"/>
-    </p>
-  </xsl:template>
-
+	
+	<xsl:template name="externalPage">
+		<xsl:param name="external"/>
+		<xsl:variable name="go_forward_link">
+			<a>
+				<xsl:attribute name="href">
+					<xsl:value-of select="$external"/>
+				</xsl:attribute>
+				<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'external.go_forward')"/>
+			</a>
+		</xsl:variable>
+		<h2><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'external.title')"/></h2>
+		<p><xsl:value-of select="util:getInterfaceTextWithDOM($interface_name, /page/@lang, 'external.text', $go_forward_link)" disable-output-escaping="yes"/></p>
+	</xsl:template>
 
 	<xsl:template match="/page"><xsl:apply-templates select="/page/pageResponse/document"/></xsl:template> <!-- this to be deleted eventually -->
Index: main/trunk/greenstone3/web/interfaces/oran/transform/pages/help.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/pages/help.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/pages/help.xsl	(revision 23813)
@@ -15,9 +15,100 @@
 
 	<!-- set page breadcrumbs -->
-	<xsl:template name="breadcrumbs"><gslib:siteLink/><gslib:rightArrow/></xsl:template>
+	<xsl:template name="breadcrumbs"><gslib:siteLink/><gslib:rightArrow/> <gslib:collectionNameLinked/><gslib:rightArrow/></xsl:template>
 
 	<!-- the page content -->
 	<xsl:template match="page">
-		Help text goes here
+		<xsl:call-template name="helpTopics"/>
+		<xsl:call-template name="findingInformationHelp"/>
+		<xsl:call-template name="readingDocsHelp"/>
+		<xsl:call-template name="searchingHelp"/>
+		<xsl:call-template name="preferencesHelp"/>
+	</xsl:template>
+	
+	<xsl:template name="helpTopics">
+		
+	</xsl:template>
+
+	<xsl:template name="findingInformationHelp">
+		<xsl:variable name="searchEnabled">
+			<xsl:choose>
+				<xsl:when test="/page/pageResponse/collection[@name=$collName]/serviceList/service[@type='query']">1</xsl:when>
+				<xsl:otherwise>0</xsl:otherwise>
+			</xsl:choose>
+		</xsl:variable>
+		
+		<xsl:variable name="numClassifiers">
+			<xsl:value-of select="count(/page/pageResponse/collection[@name=$collName]/serviceList/service[@name = 'ClassifierBrowse']/classifierList/classifier)"/>
+		</xsl:variable>
+
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.findinginformationtitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.findinginformation', $searchEnabled + $numClassifiers)"/>
+		
+		<!-- using actual <ul> and <li> tags here would cause the XML parser to break -->
+		<xsl:text disable-output-escaping="yes">&lt;ul&gt;</xsl:text>
+		<xsl:if test="$searchEnabled = 1">
+			<xsl:text disable-output-escaping="yes">&lt;li&gt;</xsl:text>
+			<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.searchdesc')"/>
+			<xsl:text disable-output-escaping="yes">&lt;/li&gt;</xsl:text>
+		</xsl:if>
+		
+		<xsl:for-each select="/page/pageResponse/collection[@name=$collName]/serviceList/service[@name = 'ClassifierBrowse']/classifierList/classifier">
+			<xsl:text disable-output-escaping="yes">&lt;li&gt;</xsl:text>
+			<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.browsedesc', ./displayItem[@name = 'name'])"/>
+			<xsl:text disable-output-escaping="yes">&lt;/li&gt;</xsl:text>
+		</xsl:for-each>
+		<xsl:text disable-output-escaping="yes">&lt;/ul&gt;</xsl:text>
+	</xsl:template>
+	
+	<xsl:template name="readingDocsHelp">
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.readingdocstitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.readingdocs')"/>
+		
+		<table>
+			<tr>
+				<td colspan="2"><img src="interfaces/oran/images/bookshelf.png"/></td>
+				<td><xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.openbookshelf')"/></td>
+			</tr>
+			<tr>
+				<td><img src="interfaces/oran/images/previous.png"/></td>
+				<td><img src="interfaces/oran/images/next.png"/></td>
+				<td><xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.sectionarrows')"/></td>
+			</tr>
+		</table>
+	</xsl:template>
+	
+	<xsl:template name="searchingHelp">
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.searchingtitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.searching')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.querytermstitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.queryterms')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.querytypetitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.querytype')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.queryscopetitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.queryscope')"/>
+	</xsl:template>
+	
+	<xsl:template name="preferencesHelp">
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.changingpreferencestitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.changingpreferences')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.collectionpreferencestitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.collectionpreferences')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.languagepreferencestitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.languagepreferences')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.presentationpreferencestitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.presentationpreferences')"/>
+		
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.searchpreferencestitle')"/>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.searchpreferences1')"/>
+		<xsl:if test="/page/pageResponse/collection[@name=$collName and (@type='mgpp' or @type='mg')]">
+			<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.mgsearchpreferences')"/>
+		</xsl:if>
+		<xsl:value-of disable-output-escaping="yes" select="util:getInterfaceText($interface_name, /page/@lang, 'help.searchpreferences2')"/>
 	</xsl:template>
 </xsl:stylesheet>
Index: main/trunk/greenstone3/web/interfaces/oran/transform/pages/pref.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/pages/pref.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/pages/pref.xsl	(revision 23813)
@@ -19,4 +19,94 @@
 	<!-- the page content -->
 	<xsl:template match="/page">
+	
+		<!-- 
+		Add some javascript to the page that notices when a preference is changed 
+		so that, if the user tries to navigate away from the page without clicking
+		the "Set preferences" button, it asks them if they want their preferences
+		saved or not 
+		-->
+		<script type="text/javascript"><xsl:text disable-output-escaping="yes">
+			var modified = false;
+					
+			function assembleURLFromForm(formElem)
+			{
+				var url = "dev";
+				var selectNodes = formElem.getElementsByTagName("select");
+				var inputNodes = formElem.getElementsByTagName("input");
+
+				for (var i = 0; i &lt; selectNodes.length; i++)
+				{
+					var current = selectNodes[i];
+					url += (url == "dev") ? "?" : "&amp;";
+					url += current.name + "=";
+					url += current.options[current.selectedIndex].text;
+				}
+				
+				for (var i = 0; i &lt; inputNodes.length; i++)
+				{
+					var current = inputNodes[i];
+					if (current.type == "hidden" || current.type == "text")
+					{
+						url += (url == "dev") ? "?" : "&amp;";
+						url += current.name + "=";
+						url += current.value;
+					}
+				}
+				return url;
+			}
+					
+			function checkModified(e)
+			{
+				if (modified)
+				{
+					var ok = confirm("Would you like to save your preferences?");
+					
+					if (ok)
+					{
+						var formElem = document.getElementById("prefform");
+						formElem.submit();
+						var xmlhttp;
+						if (window.XMLHttpRequest)
+						{
+							xmlhttp=new XMLHttpRequest();
+						}
+						else
+						{
+							xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
+						}
+						//assembleURLFromForm(formElem);
+						xmlhttp.open("GET",assembleURLFromForm(formElem),false);
+						xmlhttp.send();
+					}
+				}
+			}
+			
+			function changed()
+			{
+				modified = true;
+			}
+			
+			function pageLoad()
+			{
+				var formElem = document.getElementById("prefform");
+			
+				var selectNodes = formElem.getElementsByTagName("select");
+				var inputNodes = formElem.getElementsByTagName("input");
+
+				YAHOO.util.Event.addListener(selectNodes, 'change', changed);
+				
+				for(var i = 0; i &lt; inputNodes.length; i++)
+				{
+					current = inputNodes[i];
+					if(current.getAttribute("type") == null)
+					{
+						YAHOO.util.Event.on(current, 'keyup', changed);
+					}
+				}
+			}
+			
+			YAHOO.util.Event.addListener(window, 'load', pageLoad);
+			YAHOO.util.Event.addListener(window, 'beforeunload', checkModified);
+		</xsl:text></script>
 
 		<xsl:variable name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
@@ -24,5 +114,5 @@
 
 		<div id="queryform">
-			<form name="PrefForm" method="get" action="{$library_name}">
+			<form name="PrefForm" method="get" action="{$library_name}" id="prefform">
 
 				<input type='hidden' name='a' value='p'/>
@@ -89,5 +179,14 @@
 				<h3><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref.searchpref')"/></h3>
 				<div id="searchprefs">
-					<xsl:variable name="hits"><xsl:choose><xsl:when test="/page/pageRequest/paramList/param[@name='hitsPerPage']"><xsl:value-of select="/page/pageRequest/paramList/param[@name='hitsPerPage']/@value"/></xsl:when><xsl:otherwise>20</xsl:otherwise></xsl:choose></xsl:variable> 
+					<xsl:variable name="hits">
+						<xsl:choose>
+							<xsl:when test="/page/pageRequest/paramList/param[@name='hitsPerPage']">
+								<xsl:value-of select="/page/pageRequest/paramList/param[@name='hitsPerPage']/@value"/>
+							</xsl:when>
+							<xsl:otherwise>
+								20
+							</xsl:otherwise>
+						</xsl:choose>
+					</xsl:variable> 
 					<div class="paramLabel">
 						<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref.hitsperpage')"/>
@@ -95,10 +194,48 @@
 					<div class="paramValue">
 						<select name="hitsPerPage">
-							<option value="20"><xsl:if test="$hits=20"><xsl:attribute name="selected"></xsl:attribute></xsl:if>20</option> 
-							<option value="50"><xsl:if test="$hits=50"><xsl:attribute name="selected"></xsl:attribute></xsl:if>50</option>
-							<option value="100"><xsl:if test="$hits=100"><xsl:attribute name="selected"></xsl:attribute></xsl:if>100</option>
-							<option value="-1"><xsl:if test="$hits=-1"><xsl:attribute name="selected"></xsl:attribute></xsl:if><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref.all')"/></option>
-						</select>
-					</div>
+							<option value="20">
+								<xsl:if test="$hits=20">
+									<xsl:attribute name="selected" />
+								</xsl:if>
+								20
+							</option> 
+							<option value="50">
+								<xsl:if test="$hits=50">
+									<xsl:attribute name="selected" />
+								</xsl:if>
+								50
+							</option>
+							<option value="100">
+								<xsl:if test="$hits=100">
+									<xsl:attribute name="selected" />
+								</xsl:if>
+								100
+							</option>
+							<option value="-1">
+								<xsl:if test="$hits=-1">
+									<xsl:attribute name="selected" />
+								</xsl:if>
+								<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref.all')"/>
+							</option>
+						</select>
+					</div>
+					
+					<br class="clear"/>
+					
+					<xsl:variable name="mdocs">
+						<xsl:choose>
+							<xsl:when test="/page/pageRequest/paramList/param[@name='maxDocs']">
+								<xsl:value-of select="/page/pageRequest/paramList/param[@name='maxDocs']/@value"/>
+							</xsl:when>
+							<xsl:otherwise>100</xsl:otherwise>
+						</xsl:choose>
+					</xsl:variable> 
+					<div class="paramLabel">
+						<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref.maxDocs')"/>
+					</div>
+					<div class="paramValue">
+						<input name="maxDocs" size="3" value="{$mdocs}" />
+					</div>
+					
 					<br class="clear"/>
 				</div>
Index: main/trunk/greenstone3/web/interfaces/oran/transform/pages/query.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/pages/query.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/pages/query.xsl	(revision 23813)
@@ -36,7 +36,10 @@
 							<xsl:for-each select="paramList/param">
 								<xsl:choose>
+									<xsl:when test="@name='case' or @name='stem' or @name='accent'">
+									</xsl:when>
 									<xsl:when test="@type='multi'">
 										<xsl:apply-templates select="."><xsl:with-param name="ns" select="$ns"/></xsl:apply-templates>
 									</xsl:when>
+									<xsl:when test="@name = 'sortBy' or @name = 'maxDocs'"></xsl:when>
 									<xsl:otherwise>
 										<xsl:variable name="pvalue"><xsl:apply-templates select="." mode="calculate-default"><xsl:with-param name="ns" select="$ns"/></xsl:apply-templates></xsl:variable>
@@ -115,5 +118,5 @@
 	</xsl:template>
 
-	<!-- invisible params - used by other stuff. in the query form, we set to teh default -->
+	<!-- invisible params - used by other stuff. in the query form, we set to the default -->
 	<xsl:template match="param[@type='invisible']">
 		<xsl:param name="ns">s1.</xsl:param>
Index: main/trunk/greenstone3/web/interfaces/oran/transform/util.xsl
===================================================================
--- main/trunk/greenstone3/web/interfaces/oran/transform/util.xsl	(revision 23809)
+++ main/trunk/greenstone3/web/interfaces/oran/transform/util.xsl	(revision 23813)
@@ -1,68 +1,63 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<xsl:stylesheet version="1.0"
-	xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-	xmlns:xslt="http://www.w3.org/1999/XSL/Transform"
-	xmlns:gslib="http://www.greenstone.org/XSL/Library"
-	xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat"
-	xmlns:util="http://org.greenstone.gsdl3.util.XSLTUtil"
-	exclude-result-prefixes="util gslib gsf xslt">
-
-	<!-- some global parameters - these are set by whoever is invoking the transformation -->
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xslt="http://www.w3.org/1999/XSL/Transform" xmlns:gslib="http://www.greenstone.org/XSL/Library" xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat" xmlns:util="http://org.greenstone.gsdl3.util.XSLTUtil" version="1.0" exclude-result-prefixes="util gslib gsf xslt">
+  <!-- some global parameters - these are set by whoever is invoking the transformation -->
   <xsl:param name="interface_name"/>
   <xsl:param name="library_name"/>
-
   <xsl:include href="xml-to-string.xsl"/>
-
   <!-- every pages ....................................................................... -->
-	<xsl:template name="siteName"><xsl:value-of select="/page/pageResponse/metadataList/metadata[@name='siteName']"/></xsl:template>
-	<xsl:template name="siteLink"><a href="./{$library_name}"><xsl:call-template name="siteName"/><xsl:text> </xsl:text></a></xsl:template>
-
-  	<xsl:variable name="a"><xsl:value-of select="/page/pageRequest/paramList/param[@name='a']/@value"/>		</xsl:variable>
-	<xsl:variable name="collections" select="/page/pageResponse/collectionList/collection"/>
-
-	<xsl:variable name="berrybasketswitch"><xsl:value-of select="/page/pageRequest/paramList/param[@name='berrybasket']/@value"/></xsl:variable>
-	<xsl:variable name="berryBasketOn" select="/page/pageRequest/paramList/param[@name='berrybasket' and @value='on']"/>
-
-	<!-- template to get the name of the current collection -->
-	<xsl:template name="collectionName">
-		<xsl:choose>
-			<xsl:when test="/page/pageResponse/collection"><xsl:value-of select="/page/pageResponse/collection/displayItem[@name='name']"/></xsl:when>
-			<xsl:otherwise>All Collections</xsl:otherwise>
-		</xsl:choose>
-	</xsl:template>
-
-	<xsl:template name="collectionNameShort">
-		<xsl:value-of select="/page/pageResponse/collection/@name"/>
-	</xsl:template>
-
-	<xsl:template name="collectionNameLinked">
-		<xsl:if test="/page/pageResponse/collection">
-			<a>
-				<xsl:attribute name="href">./<xsl:value-of select="$library_name"/>?a=p&amp;sa=about&amp;c=<xsl:call-template name="collectionNameShort"/></xsl:attribute>
-				<xsl:call-template name="collectionName"/>
-			</a>
-		</xsl:if>
-	</xsl:template>
-
-	<!-- text to get the name of the current service ("Browse","Search" etc) -->
-	<xsl:template name="serviceName">
-		<xsl:value-of select="/page/pageResponse/service/displayItem[@name='name']"/>
-	</xsl:template>
-
-	<xsl:template name="textDirectionAttribute">
-		<xsl:attribute name="dir">
-			<xsl:choose>
-				<xsl:when test="/page/@lang='ar' or /page/@lang='fa' or /page/@lang='he' or /page/@lang='ur' or /page/@lang='ps' or /page/@lang='prs'">rtl</xsl:when>
-				<xsl:otherwise>ltr</xsl:otherwise>
-			</xsl:choose>
-		</xsl:attribute>
-	</xsl:template>
-
-	<xsl:template name="actionClass">
-		<xsl:attribute name="class"><xsl:value-of select="/page/pageRequest/@action"/>Action <xsl:if test="/page/pageRequest/@subaction"><xsl:value-of select="/page/pageRequest/@subaction"/>Subaction</xsl:if></xsl:attribute>
-	</xsl:template>
-
-	<!-- username, if logged in -->
-	<!--
+  <xsl:template name="siteName">
+    <xsl:value-of select="/page/pageResponse/metadataList/metadata[@name='siteName']"/>
+  </xsl:template>
+  <xsl:template name="siteLink">
+    <a href="./{$library_name}">
+      <xsl:call-template name="siteName"/>
+      <xsl:text> </xsl:text>
+    </a>
+  </xsl:template>
+  <xsl:variable name="a">
+    <xsl:value-of select="/page/pageRequest/paramList/param[@name='a']/@value"/>
+  </xsl:variable>
+  <xsl:variable name="collections" select="/page/pageResponse/collectionList/collection"/>
+  <xsl:variable name="berrybasketswitch">
+    <xsl:value-of select="/page/pageRequest/paramList/param[@name='berrybasket']/@value"/>
+  </xsl:variable>
+  <xsl:variable name="berryBasketOn" select="/page/pageRequest/paramList/param[@name='berrybasket' and @value='on']"/>
+  <!-- template to get the name of the current collection -->
+  <xsl:template name="collectionName">
+    <xsl:choose>
+      <xsl:when test="/page/pageResponse/collection">
+        <xsl:value-of select="/page/pageResponse/collection/displayItem[@name='name']"/>
+      </xsl:when>
+      <xsl:otherwise>All Collections</xsl:otherwise>
+    </xsl:choose>
+  </xsl:template>
+  <xsl:template name="collectionNameShort">
+    <xsl:value-of select="/page/pageResponse/collection/@name"/>
+  </xsl:template>
+  <xsl:template name="collectionNameLinked">
+    <xsl:if test="/page/pageResponse/collection">
+      <a>
+        <xsl:attribute name="href">./<xsl:value-of select="$library_name"/>?a=p&amp;sa=about&amp;c=<xsl:call-template name="collectionNameShort"/></xsl:attribute>
+        <xsl:call-template name="collectionName"/>
+      </a>
+    </xsl:if>
+  </xsl:template>
+  <!-- text to get the name of the current service ("Browse","Search" etc) -->
+  <xsl:template name="serviceName">
+    <xsl:value-of select="/page/pageResponse/service/displayItem[@name='name']"/>
+  </xsl:template>
+  <xsl:template name="textDirectionAttribute">
+    <xsl:attribute name="dir">
+      <xsl:choose>
+        <xsl:when test="/page/@lang='ar' or /page/@lang='fa' or /page/@lang='he' or /page/@lang='ur' or /page/@lang='ps' or /page/@lang='prs'">rtl</xsl:when>
+        <xsl:otherwise>ltr</xsl:otherwise>
+      </xsl:choose>
+    </xsl:attribute>
+  </xsl:template>
+  <xsl:template name="actionClass">
+    <xsl:attribute name="class"><xsl:value-of select="/page/pageRequest/@action"/>Action <xsl:if test="/page/pageRequest/@subaction"><xsl:value-of select="/page/pageRequest/@subaction"/>Subaction</xsl:if></xsl:attribute>
+  </xsl:template>
+  <!-- username, if logged in -->
+  <!--
 	<xsl:template name="username">
 		<xsl:if test="$un_s!=''">
@@ -73,27 +68,26 @@
 	</xsl:template>
 	-->
-
-    <xsl:template name="defaultDividerBar">
-   <xsl:param name='text'/>
-      <xsl:choose>
+  <xsl:template name="defaultDividerBar">
+    <xsl:param name="text"/>
+    <xsl:choose>
       <xsl:when test="$text">
-	 <div class="divbar"><xsl:value-of select="$text"/></div>
+        <div class="divbar">
+          <xsl:value-of select="$text"/>
+        </div>
       </xsl:when>
       <xsl:otherwise>
-	 <div class="divbar"><xsl:text disable-output-escaping="yes">&amp;nbsp;</xsl:text></div>
+        <div class="divbar">
+          <xsl:text disable-output-escaping="yes">&amp;nbsp;</xsl:text>
+        </div>
       </xsl:otherwise>
     </xsl:choose>
   </xsl:template>
-
-
-    <xsl:template match="error">
+  <xsl:template match="error">
     Error: <xsl:value-of select="."/>
   </xsl:template>
-
-
-<xsl:template name="displayErrorsIfAny">
-      <xsl:if test="descendant::error">
+  <xsl:template name="displayErrorsIfAny">
+    <xsl:if test="descendant::error">
       <script language="Javascript">
-	<xsl:text disable-output-escaping="yes">
+        <xsl:text disable-output-escaping="yes">
 	  function removeAllChildren(node) {
 	    while (node.hasChildNodes()) {
@@ -107,70 +101,72 @@
 	      hide_link = document.getElementById("hide");
 	      removeAllChildren(hide_link);
-	      hide_link.appendChild(document.createTextNode("</xsl:text><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'hide_error')"/><xsl:text disable-output-escaping="yes">"));
+	      hide_link.appendChild(document.createTextNode("</xsl:text>
+        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'hide_error')"/>
+        <xsl:text disable-output-escaping="yes">"));
 	    } else {
 	      obj.style.display = "none";
 	      hide_link = document.getElementById("hide");
 	      removeAllChildren(hide_link);
-	      hide_link.appendChild(document.createTextNode("</xsl:text><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/><xsl:text disable-output-escaping="yes">"));
+	      hide_link.appendChild(document.createTextNode("</xsl:text>
+        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/>
+        <xsl:text disable-output-escaping="yes">"));
 	    }
 	  }
 	</xsl:text>
       </script>
-      <p align='right'><a id="hide" href="javascript:toggleHideError(error);"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/></a></p>
+      <p align="right">
+        <a id="hide" href="javascript:toggleHideError(error);">
+          <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/>
+        </a>
+      </p>
       <div id="error" style="display: none;">
-	<xsl:apply-templates select="descendant::error"/>
+        <xsl:apply-templates select="descendant::error"/>
       </div>
     </xsl:if>
-</xsl:template>
-
-
-	<xsl:template name="noTextBar">
-		<xsl:text disable-output-escaping="yes">&amp;nbsp;</xsl:text>
-	</xsl:template>
-	
-	
-	<xsl:template name="poweredByGS3TextBar">
-		<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gs3power')"/>
-	</xsl:template>
-
-	<xsl:template name="rightArrow"><xsl:text disable-output-escaping="yes"> &amp;raquo; </xsl:text></xsl:template>
-
-
-
-	<!-- site home ....................................................................... -->
-
-<xsl:template name="siteHomePageTitle">
- <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
-<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/><xsl:text> </xsl:text>
-</xsl:template>
-
-
-    <xsl:template name="selectACollectionTextBar">
-  	 <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.select_a_collection')"/>
-  </xsl:template>
-	<xsl:template name="crossCollectionQuickSearchForm">
-		<xsl:apply-templates select="serviceList/service[@name='TextQuery']"/>
-	</xsl:template>
-	
-	<xsl:template match="service[@name='TextQuery']">
-		<form name="QuickSearch" method="get" action="{$library_name}">
-			<input type="hidden" name="a" value="q"/>
-			<input type="hidden" name="rt" value="rd"/>
-			<input type="hidden" name="s" value="{@name}"/>
-			<input type="hidden" name="s1.collection" value="all"/>
-			<input type="text" name="s1.query" size="20"/>
-			<input type="submit"><xsl:attribute name="value"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.quick_search')"/></xsl:attribute></input>
-		</form>
-	</xsl:template>
-
-	<xsl:template name="collectionLinkWithImage">
-		<xsl:choose>
-			<xsl:when test="displayItem[@name='icon']">
-				<a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
-					<img class="collectionLinkImage">
-						<xsl:attribute name="alt"></xsl:attribute>
-						<xsl:attribute name="src">sites/localsite/collect/<xsl:value-of select="@name"/>/images/<xsl:value-of select="displayItem[@name='icon']"/></xsl:attribute>
-					</img>
-<!--
+  </xsl:template>
+  <xsl:template name="noTextBar">
+    <xsl:text disable-output-escaping="yes">&amp;nbsp;</xsl:text>
+  </xsl:template>
+  <xsl:template name="poweredByGS3TextBar">
+    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gs3power')"/>
+  </xsl:template>
+  <xsl:template name="rightArrow">
+    <xsl:text disable-output-escaping="yes"> &amp;raquo; </xsl:text>
+  </xsl:template>
+  <!-- site home ....................................................................... -->
+  <xsl:template name="siteHomePageTitle">
+    <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
+    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/>
+    <xsl:text> </xsl:text>
+  </xsl:template>
+  <xsl:template name="selectACollectionTextBar">
+    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.select_a_collection')"/>
+  </xsl:template>
+  <xsl:template name="crossCollectionQuickSearchForm">
+    <xsl:apply-templates select="serviceList/service[@name='TextQuery']"/>
+  </xsl:template>
+  <xsl:template match="service[@name='TextQuery']">
+    <form name="QuickSearch" method="get" action="{$library_name}">
+      <input type="hidden" name="a" value="q"/>
+      <input type="hidden" name="rt" value="rd"/>
+      <input type="hidden" name="s" value="{@name}"/>
+      <input type="hidden" name="s1.collection" value="all"/>
+      <input type="text" name="s1.query" size="20"/>
+      <input type="submit">
+        <xsl:attribute name="value">
+          <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.quick_search')"/>
+        </xsl:attribute>
+      </input>
+    </form>
+  </xsl:template>
+  <xsl:template name="collectionLinkWithImage">
+    <xsl:choose>
+      <xsl:when test="displayItem[@name='icon']">
+        <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
+          <img class="collectionLinkImage">
+            <xsl:attribute name="alt"/>
+            <xsl:attribute name="src">sites/localsite/collect/<xsl:value-of select="@name"/>/images/<xsl:value-of select="displayItem[@name='icon']"/></xsl:attribute>
+          </img>
+          <!--
 					<div class="collectionLink">
 						<xsl:attribute name="style">background-image: url(/sites/localsite/collect/<xsl:value-of select="@name"/>/images/<xsl:value-of select="displayItem[@name='icon']"/>);</xsl:attribute>
@@ -178,357 +174,393 @@
 					</div>
 -->
-				</a>
+        </a>
+      </xsl:when>
+      <xsl:otherwise>
+        <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
+          <div class="collectionLink">
+            <xsl:value-of select="displayItem[@name='name']"/>
+          </div>
+        </a>
+      </xsl:otherwise>
+    </xsl:choose>
+  </xsl:template>
+  <xsl:template name="serviceClusterList">
+    <xsl:apply-templates select="serviceClusterList"/>
+  </xsl:template>
+  <xsl:template match="serviceClusterList">
+    <xsl:for-each select="serviceCluster">
+      <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
+        <xsl:value-of select="@name"/>
+        <xsl:value-of select="displayItem[@name='name']"/>
+      </a>
+    </xsl:for-each>
+  </xsl:template>
+  <xsl:template name="serviceLink">
+    <div class="paramLabel">
+      <a href="{$library_name}?a=q&amp;rt=d&amp;s={@name}">
+        <xsl:value-of select="displayItem[@name='name']"/>
+      </a>
+    </div>
+    <div class="paramValue">
+      <xsl:value-of select="displayItem[@name='description']"/>
+    </div>
+    <br class="clear"/>
+  </xsl:template>
+  <xsl:template name="authenticationLink">
+    <xsl:for-each select="serviceList/service[@type='authen']">
+      <li>
+        <a href="{$library_name}?a=g&amp;rt=r&amp;sa=authen&amp;s={@name}&amp;s1.aup=Login&amp;s1.un=&amp;s1.asn=">
+          <xsl:value-of select="displayItem[@name='name']"/>
+        </a>
+        <xsl:value-of select="displayItem[@name='description']"/>
+      </li>
+    </xsl:for-each>
+  </xsl:template>
+  <xsl:template name="libraryInterfaceLink">
+    <li>
+      <a href="{$library_name}?a=p&amp;sa=gli4gs3">
+        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.librarian_interface')"/>
+      </a>
+    </li>
+  </xsl:template>
+  <xsl:template name="greenstoneLogoAlternateText">
+    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/>
+  </xsl:template>
+  <!-- about page - collection home ....................................................................... -->
+  <xsl:variable name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
+  <xsl:param name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
+  <xsl:param name="pageType"/>
+  <xsl:variable name="this-element" select="/page/pageResponse/collection|/page/pageResponse/serviceCluster"/>
+  <xsl:variable name="this-service" select="/page/pageResponse/service/@name"/>
+  <xsl:template name="aboutCollectionPageTitle">
+    <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
+    <xsl:value-of select="/page/pageResponse/collection/displayItem[@name='name']"/>
+    <xsl:text> </xsl:text>
+  </xsl:template>
+  <xsl:template name="collectionHomeLinkWithLogoIfAvailable">
+    <a href="{$library_name}?a=p&amp;sa=about&amp;c={$collName}">
+      <xsl:choose>
+        <xsl:when test="$this-element/displayItem[@name='icon']">
+          <img border="0">
+            <xsl:attribute name="src"><xsl:value-of select="$this-element/metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="$this-element/displayItem[@name='icon']"/></xsl:attribute>
+            <xsl:attribute name="alt">
+              <xsl:value-of select="$this-element/displayItem[@name='name']"/>
+            </xsl:attribute>
+            <xsl:attribute name="title">
+              <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'aboutpage')"/>
+            </xsl:attribute>
+          </img>
+        </xsl:when>
+        <xsl:otherwise>
+          <xsl:value-of select="$this-element/displayItem[@name='name']"/>
+        </xsl:otherwise>
+      </xsl:choose>
+    </a>
+  </xsl:template>
+  <xsl:template name="homeButtonTop">
+    <a href="{$library_name}?a=p&amp;sa=home">
+      <xsl:attribute name="title">
+        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_tip')"/>
+      </xsl:attribute>
+      <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/>
+    </a>
+  </xsl:template>
+  <xsl:template name="helpButtonTop">
+    <xsl:choose>
+      <xsl:when test="$pageType='help'">
+        <li>
+          <a>
+            <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
+          </a>
+        </li>
+      </xsl:when>
+      <xsl:otherwise>
+        <li>
+          <a href="{$library_name}?a=p&amp;sa=help&amp;c={$collName}">
+            <xsl:attribute name="title">
+              <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_tip')"/>
+            </xsl:attribute>
+            <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
+          </a>
+        </li>
+      </xsl:otherwise>
+    </xsl:choose>
+  </xsl:template>
+  <xsl:template name="preferencesButtonTop">
+    <xsl:choose>
+      <xsl:when test="$pageType='pref'">
+        <li>
+          <a>
+            <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
+          </a>
+        </li>
+      </xsl:when>
+      <xsl:otherwise>
+        <li>
+          <a href="{$library_name}?a=p&amp;sa=pref&amp;c={$collName}">
+            <xsl:attribute name="title">
+              <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_tip')"/>
+            </xsl:attribute>
+            <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
+          </a>
+        </li>
+      </xsl:otherwise>
+    </xsl:choose>
+  </xsl:template>
+  <xsl:template name="servicesNavigationBar">
+    <xsl:for-each select="$this-element/serviceList/service">
+      <xsl:variable name="action">
+        <xsl:choose>
+          <xsl:when test="@name=$this-service">CURRENT</xsl:when>
+          <xsl:when test="@type='query'">q</xsl:when>
+          <xsl:when test="@type='browse'">b</xsl:when>
+          <xsl:when test="@type='process'">pr</xsl:when>
+          <xsl:when test="@type='applet'">a</xsl:when>
+          <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
+        </xsl:choose>
+      </xsl:variable>
+      <xsl:choose>
+        <xsl:when test="$action='CURRENT'">
+          <li>
+            <a>
+              <xsl:value-of select="displayItem[@name='name']"/>
+            </a>
+          </li>
+        </xsl:when>
+        <xsl:when test="$action !='DO_NOT_DISPLAY'">
+          <li>
+            <a href="{$library_name}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}">
+              <xsl:if test="displayItem[@name='description']">
+                <xsl:attribute name="title">
+                  <xsl:value-of select="displayItem[@name='description']"/>
+                </xsl:attribute>
+              </xsl:if>
+              <xsl:value-of select="displayItem[@name='name']"/>
+            </a>
+          </li>
+        </xsl:when>
+      </xsl:choose>
+    </xsl:for-each>
+  </xsl:template>
+  <xsl:template name="collectionDescriptionTextAndServicesLinks">
+    <xsl:apply-templates select="pageResponse/collection|serviceCluster"/>
+  </xsl:template>
+  <xsl:template match="collection|serviceCluster">
+    <xsl:value-of select="displayItem[@name='description']" disable-output-escaping="yes"/>
+    <xsl:apply-templates select="serviceList">
+      <xsl:with-param name="collName" select="$collName"/>
+    </xsl:apply-templates>
+  </xsl:template>
+  <xsl:template match="serviceList">	
+	<xsl:param name="collName"/>
+	<xsl:if test="service[not(@type = 'query' or @type = 'browse' or @type = 'retrieve')]">
+		<h3>
+		  <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.services')"/>
+		</h3>
+		<p>
+		  <xsl:choose>
+			<xsl:when test="service">
+			  <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.servicehelp')"/>
 			</xsl:when>
 			<xsl:otherwise>
-				<a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
-					<div class="collectionLink">
-						<xsl:value-of select="displayItem[@name='name']"/>
-					</div>
-				</a>
+			  <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.noservices')"/>
 			</xsl:otherwise>
-		</xsl:choose>
-	</xsl:template>
-
-
-	<xsl:template name="serviceClusterList">
-		<xsl:apply-templates select="serviceClusterList"/>
-	</xsl:template>
-	
-	  <xsl:template match="serviceClusterList">
-	    <xsl:for-each select="serviceCluster">
-	      <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}"><xsl:value-of select='@name'/><xsl:value-of select="displayItem[@name='name']"/></a>
-	    </xsl:for-each>
-	  </xsl:template>
-
-	
-	<xsl:template name="serviceLink">
-		<div class="paramLabel"><a href="{$library_name}?a=q&amp;rt=d&amp;s={@name}"><xsl:value-of select="displayItem[@name='name']"/></a></div>
-		<div class="paramValue"><xsl:value-of select="displayItem[@name='description']"/></div>
-		<br class="clear"/>
-	</xsl:template>
-
-
-   <xsl:template name="authenticationLink">
-   <xsl:for-each select="serviceList/service[@type='authen']">
-      <li><a href="{$library_name}?a=g&amp;rt=r&amp;sa=authen&amp;s={@name}&amp;s1.aup=Login&amp;s1.un=&amp;s1.asn="><xsl:value-of select="displayItem[@name='name']"/></a><xsl:value-of select="displayItem[@name='description']"/></li></xsl:for-each>
-  </xsl:template>
-   <xsl:template name="libraryInterfaceLink">
-   <li><a href="{$library_name}?a=p&amp;sa=gli4gs3"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.librarian_interface')"/></a></li>
-  </xsl:template>
-<xsl:template name="greenstoneLogoAlternateText">
-<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/>
-</xsl:template>
-
-<!-- about page - collection home ....................................................................... -->
-<xsl:variable name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
-<xsl:param name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
-<xsl:param name="pageType"/>
-<xsl:variable name="this-element" select="/page/pageResponse/collection|/page/pageResponse/serviceCluster"/>
-<xsl:variable name="this-service" select="/page/pageResponse/service/@name"/>
-
-
-<xsl:template name="aboutCollectionPageTitle">
- <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
-<xsl:value-of select="/page/pageResponse/collection/displayItem[@name='name']"/><xsl:text> </xsl:text>
-</xsl:template>
-
-	
-<xsl:template name="collectionHomeLinkWithLogoIfAvailable">
-<a href="{$library_name}?a=p&amp;sa=about&amp;c={$collName}">
-	  <xsl:choose>
-	    <xsl:when test="$this-element/displayItem[@name='icon']">
-	      <img border="0">
-		<xsl:attribute name="src">
-		  <xsl:value-of select="$this-element/metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="$this-element/displayItem[@name='icon']"/>
-		</xsl:attribute>	
-		<xsl:attribute name="alt">
-		  <xsl:value-of select="$this-element/displayItem[@name='name']"/>
-		</xsl:attribute>
-		<xsl:attribute name="title">
-		  <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'aboutpage')"/>
-		</xsl:attribute>
-	      </img>
-	    </xsl:when>
-	    <xsl:otherwise>
-	      <xsl:value-of select="$this-element/displayItem[@name='name']"/>
-	    </xsl:otherwise>
-	  </xsl:choose>
-	</a>
-</xsl:template>
-
-
-<xsl:template name="homeButtonTop">
-<a href="{$library_name}?a=p&amp;sa=home"><xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_tip')"/></xsl:attribute>
-<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/></a>
-</xsl:template>
-
-
-<xsl:template name="helpButtonTop">
+		  </xsl:choose>
+		</p>
+		<xsl:if test="service">
+		  <div id="servicelist">
+			<xsl:for-each select="service">
+			  <xsl:sort select="position()" order="descending" data-type="number"/>
+			  <xsl:variable name="action">
+				<xsl:choose>
+				  <xsl:when test="@type='query'">q</xsl:when>
+				  <xsl:when test="@type='browse'">b</xsl:when>
+				  <xsl:when test="@type='process'">pr</xsl:when>
+				  <xsl:when test="@type='applet'">a</xsl:when>
+				  <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
+				</xsl:choose>
+			  </xsl:variable>
+			  <xsl:if test="$action != 'DO_NOT_DISPLAY'">
+				<div class="paramLabel">
+				  <a href="{$library_name}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}">
+					<xsl:value-of select="displayItem[@name='name']"/>
+				  </a>
+				</div>
+				<div class="paramLabel">
+				  <xsl:value-of select="displayItem[@name='description']"/>
+				</div>
+				<br class="clear"/>
+			  </xsl:if>
+			</xsl:for-each>
+		  </div>
+		</xsl:if>
+	</xsl:if>
+  </xsl:template>
+  <!-- classifier page ............................................................................ -->
+  <xsl:template name="collapsedNavigationTab">
+    <xsl:param name="type"/>
+    <xsl:variable name="isCurrent" select="/page/pageResponse/service[@type=$type]"/>
+    <li>
+      <xsl:if test="$isCurrent">
+        <xsl:attribute name="class">current</xsl:attribute>
+      </xsl:if>
+      <a>
+        <xsl:if test="service[@name=$type]/displayItem[@name='description']">
+          <xsl:attribute name="title">
+            <xsl:value-of select="service[@name=$type]/displayItem[@name='description']"/>
+          </xsl:attribute>
+        </xsl:if>
+        <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=q&amp;rt=d&amp;s=<xsl:value-of select="service[@type=$type]/@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/></xsl:attribute>
+        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, $type)"/>
+      </a>
+    </li>
+  </xsl:template>
+  <xsl:template name="navigationTab">
+    <xsl:variable name="isCurrent" select="@name=/page/pageResponse/service/@name"/>
+    <xsl:variable name="action">
+      <xsl:choose>
+        <xsl:when test="@type='query'">q</xsl:when>
+        <xsl:when test="@type='browse'">b</xsl:when>
+        <xsl:when test="@type='process'">pr</xsl:when>
+        <xsl:when test="@type='applet'">a</xsl:when>
+        <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
+      </xsl:choose>
+    </xsl:variable>
+    <xsl:if test="$action!='DO_NOT_DISPLAY'">
+      <li>
+        <xsl:if test="$isCurrent">
+          <xsl:attribute name="class">current</xsl:attribute>
+        </xsl:if>
+        <a>
+          <xsl:if test="displayItem[@name='description']">
+            <xsl:attribute name="title">
+              <xsl:value-of select="displayItem[@name='description']"/>
+            </xsl:attribute>
+          </xsl:if>
+          <xsl:choose>
+            <xsl:when test="classifierList/classifier/@name">
+              <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=<xsl:value-of select="$action"/>&amp;rt=s&amp;s=<xsl:value-of select="@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;cl=<xsl:value-of select="classifierList/classifier/@name"/></xsl:attribute>
+            </xsl:when>
+            <xsl:otherwise>
+              <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=<xsl:value-of select="$action"/>&amp;rt=d&amp;s=<xsl:value-of select="@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/></xsl:attribute>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:value-of select="displayItem[@name='name']"/>
+        </a>
+      </li>
+    </xsl:if>
+  </xsl:template>
+  <xsl:template name="classifierLink">
+    <xsl:if test="@name=/page/pageResponse/classifier/@name">
+      <xsl:attribute name="class">current</xsl:attribute>
+    </xsl:if>
+    <a href="{$library_name}?a=b&amp;rt=r&amp;s={/page/pageResponse/service/@name}&amp;c={/page/pageResponse/collection/@name}&amp;cl={@name}">
+      <xsl:value-of select="displayItem[@name='description']"/>
+    </a>
+  </xsl:template>
+  <!-- query page ............................................................................ -->
+  <xsl:template name="indexName">
+    <xsl:value-of select="/page/pageResponse/service/displayItem[@name='name']"/>
+  </xsl:template>
+  <xsl:template name="queryPageCollectionName">
     <xsl:choose>
-      <xsl:when test="$pageType='help'">
-	<li><a><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/></a></li>
+      <xsl:when test="/page/pageResponse/collection">
+        <gslib:aboutCollectionPageTitle/>
       </xsl:when>
-      <xsl:otherwise>
-	<li><a href="{$library_name}?a=p&amp;sa=help&amp;c={$collName}"><xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_tip')"/></xsl:attribute>
-	    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
-	  </a></li>
-      </xsl:otherwise>
+      <xsl:otherwise>Cross-Collection</xsl:otherwise>
     </xsl:choose>
-</xsl:template>
-
-
-	<xsl:template name="preferencesButtonTop">
-		<xsl:choose>
-			<xsl:when test="$pageType='pref'">
-				<li><a><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/></a></li>
-			</xsl:when>
-			<xsl:otherwise>
-				<li><a href="{$library_name}?a=p&amp;sa=pref&amp;c={$collName}"><xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_tip')"/></xsl:attribute>
-					<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
-				</a></li>
-			</xsl:otherwise>
-		</xsl:choose>
-	</xsl:template>
-
-	<xsl:template name="servicesNavigationBar">
-		<xsl:for-each select="$this-element/serviceList/service">
-			<xsl:variable name="action"><xsl:choose>
-				<xsl:when test="@name=$this-service">CURRENT</xsl:when>
-				<xsl:when test="@type='query'">q</xsl:when>
-				<xsl:when test="@type='browse'">b</xsl:when>
-				<xsl:when test="@type='process'">pr</xsl:when>
-				<xsl:when test="@type='applet'">a</xsl:when>
-				<xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
-			</xsl:choose></xsl:variable>
-			<xsl:choose>
-				<xsl:when test="$action='CURRENT'">
-					<li><a><xsl:value-of select="displayItem[@name='name']"/></a></li>
-				</xsl:when>
-				<xsl:when test="$action !='DO_NOT_DISPLAY'">
-					<li><a href="{$library_name}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}"><xsl:if test="displayItem[@name='description']"><xsl:attribute name='title'><xsl:value-of select="displayItem[@name='description']"/></xsl:attribute></xsl:if><xsl:value-of select="displayItem[@name='name']"/></a></li>
-				</xsl:when>
-			</xsl:choose>
-		</xsl:for-each>
-	</xsl:template>
-
-
-	<xsl:template name="collectionDescriptionTextAndServicesLinks">
-		<xsl:apply-templates select="pageResponse/collection|serviceCluster"/>
-	</xsl:template>
-
-	<xsl:template match="collection|serviceCluster">
-		<xsl:value-of select="displayItem[@name='description']" disable-output-escaping="yes"/>
-		<xsl:apply-templates select="serviceList">
-			<xsl:with-param name="collName" select="$collName"/>
-		</xsl:apply-templates>
-	</xsl:template>
-
-
-	<xsl:template match="serviceList">
-		<xsl:param name="collName"/>
-		<h3><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.services')"/></h3>
-		<p>
-			<xsl:choose>
-				<xsl:when test="service">
-					<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.servicehelp')"/>
-				</xsl:when>
-				<xsl:otherwise>
-					<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.noservices')"/>
-				</xsl:otherwise>
-			</xsl:choose>
-		</p>
-
-		<xsl:if test="service">
-			<div id="servicelist">
-				<xsl:for-each select="service">
-					<xsl:sort select="position()" order="descending" data-type="number"/>
-
-					<xsl:variable name="action"><xsl:choose>
-						<xsl:when test="@type='query'">q</xsl:when>
-						<xsl:when test="@type='browse'">b</xsl:when>
-						<xsl:when test="@type='process'">pr</xsl:when>
-						<xsl:when test="@type='applet'">a</xsl:when>
-						<xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
-					</xsl:choose></xsl:variable>
-					<xsl:if test="$action != 'DO_NOT_DISPLAY'">
-						<div class="paramLabel"><a href="{$library_name}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}"><xsl:value-of select="displayItem[@name='name']"/></a></div>
-						<div class="paramLabel"><xsl:value-of select="displayItem[@name='description']"/></div>
-						<br class="clear"/>
-					</xsl:if>
-				</xsl:for-each>
-			</div>
-		</xsl:if>
-	</xsl:template>
-
-
-
-<!-- classifier page ............................................................................ -->
-
-<xsl:template name="collapsedNavigationTab">
-	<xsl:param name="type"/>
-	<xsl:variable name="isCurrent" select="/page/pageResponse/service[@type=$type]"/>
-	<li>
-		<xsl:if test="$isCurrent">
-			<xsl:attribute name="class">current</xsl:attribute>
-		</xsl:if>
-		<a>
-			<xsl:if test="service[@name=$type]/displayItem[@name='description']"><xsl:attribute name='title'><xsl:value-of select="service[@name=$type]/displayItem[@name='description']"/></xsl:attribute></xsl:if>
-			<xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=q&amp;rt=d&amp;s=<xsl:value-of select="service[@type=$type]/@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/></xsl:attribute>
-			<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, $type)"/>
-		</a>
-	</li>
-</xsl:template>
-
-<xsl:template name="navigationTab">
-
-	<xsl:variable name="isCurrent" select="@name=/page/pageResponse/service/@name"/>
-
-	<xsl:variable name="action"><xsl:choose>
-		<xsl:when test="@type='query'">q</xsl:when>
-		<xsl:when test="@type='browse'">b</xsl:when>
-		<xsl:when test="@type='process'">pr</xsl:when>
-		<xsl:when test="@type='applet'">a</xsl:when>
-		<xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
-	</xsl:choose></xsl:variable>
-
-	<xsl:if test="$action!='DO_NOT_DISPLAY'">
-		<li>
-			<xsl:if test="$isCurrent">
-				<xsl:attribute name="class">current</xsl:attribute>
-			</xsl:if>
-			<a>
-				<xsl:if test="displayItem[@name='description']">
-					<xsl:attribute name='title'><xsl:value-of select="displayItem[@name='description']"/></xsl:attribute>
-				</xsl:if>
-				<xsl:choose>
-					<xsl:when test="classifierList/classifier/@name">
-						<xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=<xsl:value-of select="$action"/>&amp;rt=s&amp;s=<xsl:value-of select="@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;cl=<xsl:value-of select="classifierList/classifier/@name"/></xsl:attribute>
-					</xsl:when>
-					<xsl:otherwise>
-						<xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=<xsl:value-of select="$action"/>&amp;rt=d&amp;s=<xsl:value-of select="@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/></xsl:attribute>
-					</xsl:otherwise>
-				</xsl:choose>
-				<xsl:value-of select="displayItem[@name='name']"/>
-			</a>
-		</li>
-	</xsl:if>
-
-</xsl:template>
-
-
-<xsl:template name="classifierLink">
-	<xsl:if test="@name=/page/pageResponse/classifier/@name"><xsl:attribute name="class">current</xsl:attribute></xsl:if>
-	<a href="{$library_name}?a=b&amp;rt=r&amp;s={/page/pageResponse/service/@name}&amp;c={/page/pageResponse/collection/@name}&amp;cl={@name}">
-		<xsl:value-of select="displayItem[@name='description']"/>
-	</a>
-</xsl:template>
-
-<!-- query page ............................................................................ -->
-
-	<xsl:template name="indexName">
-		<xsl:value-of select="/page/pageResponse/service/displayItem[@name='name']"/>
-	</xsl:template>
-
-<xsl:template name="queryPageCollectionName">
-	<xsl:choose><xsl:when test="/page/pageResponse/collection"><gslib:aboutCollectionPageTitle/></xsl:when><xsl:otherwise>Cross-Collection</xsl:otherwise></xsl:choose>
-</xsl:template>
-
-
-
-
-
-<!--
+  </xsl:template>
+  <!--
 BERRY BASKET TEMPLATES
 These get used on many different pages to add the
 berry basket function to the site
 -->
-
-<!-- put the drag&drop berry basket on the page -->
-<xsl:template name="berryBasket">
-	<xsl:if test="$berryBasketOn">
-		<div id="berrybasket" class="hide">
-			<span>Berry Basket</span>
-			<span id="berryBasketExpandCollapseLinks" style="display: none;">
-				<a id="berryBasketExpandLink" href="javascript:showBasket()">Expand</a>
-				<a id="berryBasketCollapseLink" style="display: none;" href="javascript:hideBasket()">Collapse</a>
-			</span>
-			<div id="baskethandle"><span><xsl:text> </xsl:text></span></div>
-			<div id ="berries"><span><xsl:text> </xsl:text></span></div>
-		</div>
-	</xsl:if>
-</xsl:template>
-
-<!-- include the required javascript and css for berry baskets -->
-<xsl:template name="berryBasketHeadTags">
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/YAHOO.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/event.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/connection.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/dom.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/dragdrop.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/ygDDPlayer.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/ygDDOnTop.js"><xsl:text> </xsl:text></script>
-	<script type="text/javascript" src="interfaces/{$interface_name}/js/berrybasket.js"><xsl:text> </xsl:text></script>
-	<link rel="stylesheet" href="interfaces/{$interface_name}/style/berry.css" type="text/css"/>
-</xsl:template>
-
-<!--
+  <!-- put the drag&drop berry basket on the page -->
+  <xsl:template name="berryBasket">
+    <xsl:if test="$berryBasketOn">
+      <div id="berrybasket" class="hide">
+        <span>Berry Basket</span>
+        <span id="berryBasketExpandCollapseLinks" style="display: none;">
+          <a id="berryBasketExpandLink" href="javascript:showBasket()">Expand</a>
+          <a id="berryBasketCollapseLink" style="display: none;" href="javascript:hideBasket()">Collapse</a>
+        </span>
+        <div id="baskethandle">
+          <span>
+            <xsl:text> </xsl:text>
+          </span>
+        </div>
+        <div id="berries">
+          <span>
+            <xsl:text> </xsl:text>
+          </span>
+        </div>
+      </div>
+    </xsl:if>
+  </xsl:template>
+  <!-- include the required javascript and css for berry baskets -->
+  <xsl:template name="berryBasketHeadTags">
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/YAHOO.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/event.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/connection.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/dom.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/dragdrop.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/ygDDPlayer.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/ygDDOnTop.js"><xsl:text> </xsl:text></script>
+    <script type="text/javascript" src="interfaces/{$interface_name}/js/berrybasket.js"><xsl:text> </xsl:text></script>
+    <link rel="stylesheet" href="interfaces/{$interface_name}/style/berry.css" type="text/css"/>
+  </xsl:template>
+  <!--
 create a little berry which can be drag&dropped onto the berry basket
 used on classifier and search result pages
 -->
-<xsl:template name="documentBerryForClassifierOrSearchPage">
-	<xsl:if test="$berryBasketOn">
-		<img class="pick" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0">
-			<xsl:attribute name="id"><xsl:value-of select="/page/pageResponse/collection/@name"/>:<xsl:value-of select="@nodeID"/></xsl:attribute>
-		</img>
-	</xsl:if>
-</xsl:template>
-
-<!--
+  <xsl:template name="documentBerryForClassifierOrSearchPage">
+    <xsl:if test="$berryBasketOn">
+      <img class="pick" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0">
+        <xsl:attribute name="id"><xsl:value-of select="/page/pageResponse/collection/@name"/>:<xsl:value-of select="@nodeID"/></xsl:attribute>
+      </img>
+    </xsl:if>
+  </xsl:template>
+  <!--
 create little berrys which can be drag&dropped onto the berry basket
 used on the document page
 -->
-<xsl:template name="documentBerryForDocumentPage">
-    <xsl:variable name="selectedNode"><xsl:value-of select="/page/pageResponse/document/@selectedNode"/></xsl:variable>
-    <xsl:variable name="rootNode"><xsl:value-of select="/page/pageResponse/document/documentNode[@nodeType='root']/@nodeID"/></xsl:variable>
-
-	<xsl:if test="$berryBasketOn">	
-		<div id="documentberries">
-			<img class='pick' id="{/page/pageResponse/collection/@name}:{$rootNode}" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0"/>
-			<span id="{/page/pageResponse/collection/@name}:{$rootNode}:root" class="documentberry">the whole document</span>
-
-			<xsl:if test="$selectedNode != $rootNode">
-				<img class='pick'  id="{/page/pageResponse/collection/@name}:{$selectedNode}" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0"/>
-				<span id="{/page/pageResponse/collection/@name}:{$selectedNode}:section" class="documentberry">the current section</span>
-			</xsl:if>
-		</div>
-	</xsl:if>
-</xsl:template>
-
-
-<!-- document page -->
-<xsl:template name="documentTitle">
-	<xsl:value-of select="/page/pageResponse/document/documentNode/metadataList/metadata[@name='Title']"/>
-</xsl:template>
-
-
-<xsl:template name="coverImage">
-	<img><xsl:attribute name='src'><xsl:value-of select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>/index/assoc/<xsl:value-of select="metadataList/metadata[@name='archivedir']"/>/cover.jpg</xsl:attribute></img>
-</xsl:template>
-
-<xsl:template name="previousNextButtons">
-	<!-- prev -->
-	<a>
-		<xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;d=<xsl:value-of select="@selectedNode"/>.pp&amp;sib=1&amp;p.s=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.s"]/@value'/>&amp;p.sa=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.sa"]/@value'/>&amp;p.a=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.a"]/@value'/></xsl:attribute>
-		<img class="lessarrow" src="interfaces/{$interface_name}/images/previous.png"/>
-	</a>
-
-	<!-- next -->
-	<a>
-		<xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;d=<xsl:value-of select="@selectedNode"/>.np&amp;sib=1&amp;p.s=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.s"]/@value'/>&amp;p.sa=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.sa"]/@value'/>&amp;p.a=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.a"]/@value'/></xsl:attribute>
-		<img class="morearrow" src="interfaces/{$interface_name}/images/next.png"/>
-	</a>
-
-</xsl:template>
-
-
+  <xsl:template name="documentBerryForDocumentPage">
+    <xsl:variable name="selectedNode">
+      <xsl:value-of select="/page/pageResponse/document/@selectedNode"/>
+    </xsl:variable>
+    <xsl:variable name="rootNode">
+      <xsl:value-of select="/page/pageResponse/document/documentNode[@nodeType='root']/@nodeID"/>
+    </xsl:variable>
+    <xsl:if test="$berryBasketOn">
+      <div id="documentberries">
+        <img class="pick" id="{/page/pageResponse/collection/@name}:{$rootNode}" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0"/>
+        <span id="{/page/pageResponse/collection/@name}:{$rootNode}:root" class="documentberry">the whole document</span>
+        <xsl:if test="$selectedNode != $rootNode">
+          <img class="pick" id="{/page/pageResponse/collection/@name}:{$selectedNode}" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0"/>
+          <span id="{/page/pageResponse/collection/@name}:{$selectedNode}:section" class="documentberry">the current section</span>
+        </xsl:if>
+      </div>
+    </xsl:if>
+  </xsl:template>
+  <!-- document page -->
+  <xsl:template name="documentTitle">
+    <xsl:value-of select="/page/pageResponse/document/documentNode/metadataList/metadata[@name='Title']"/>
+  </xsl:template>
+  <xsl:template name="coverImage">
+    <img>
+      <xsl:attribute name="src"><xsl:value-of select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>/index/assoc/<xsl:value-of select="metadataList/metadata[@name='archivedir']"/>/cover.jpg</xsl:attribute>
+    </img>
+  </xsl:template>
+  <xsl:template name="previousNextButtons">
+    <!-- prev -->
+    <a>
+      <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;d=<xsl:value-of select="@selectedNode"/>.pp&amp;sib=1&amp;p.s=<xsl:value-of select="/page/pageRequest/paramList/param[@name=&quot;p.s&quot;]/@value"/>&amp;p.sa=<xsl:value-of select="/page/pageRequest/paramList/param[@name=&quot;p.sa&quot;]/@value"/>&amp;p.a=<xsl:value-of select="/page/pageRequest/paramList/param[@name=&quot;p.a&quot;]/@value"/></xsl:attribute>
+      <img class="lessarrow" src="interfaces/{$interface_name}/images/previous.png"/>
+    </a>
+    <!-- next -->
+    <a>
+      <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;d=<xsl:value-of select="@selectedNode"/>.np&amp;sib=1&amp;p.s=<xsl:value-of select="/page/pageRequest/paramList/param[@name=&quot;p.s&quot;]/@value"/>&amp;p.sa=<xsl:value-of select="/page/pageRequest/paramList/param[@name=&quot;p.sa&quot;]/@value"/>&amp;p.a=<xsl:value-of select="/page/pageRequest/paramList/param[@name=&quot;p.a&quot;]/@value"/></xsl:attribute>
+      <img class="morearrow" src="interfaces/{$interface_name}/images/next.png"/>
+    </a>
+  </xsl:template>
 </xsl:stylesheet>
