Index: trunk/gsdl3/web/interfaces/default/transform/style.xsl
===================================================================
--- trunk/gsdl3/web/interfaces/default/transform/style.xsl	(revision 8648)
+++ trunk/gsdl3/web/interfaces/default/transform/style.xsl	(revision 8659)
@@ -91,41 +91,8 @@
 	</td>
 	<td align="right">
-	  <table cellspacing='4'>
-	    <tr>
-	      <td class="gsbutton">
-		<a class="gsbutton" 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>
-	      </td>
-	      <xsl:choose>
-		<xsl:when test="$pageType='help'">
-		  <td class="gsbuttonoff">
-		    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
-		  </td>
-		</xsl:when>
-		<xsl:otherwise>
-		  <td class="gsbutton">
-		    <a class="gsbutton" 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>
-		  </td>
-		</xsl:otherwise>
-	      </xsl:choose>
-	      <xsl:choose>
-		<xsl:when test="$pageType='pref'">
-		  <td class="gsbuttonoff">
-		    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
-		  </td>
-		</xsl:when>
-		<xsl:otherwise>
-		  <td class="gsbutton">
-		    <a class="gsbutton" 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>
-		  </td>
-		</xsl:otherwise>
-	      </xsl:choose>
-	    </tr>
-	  </table>
+	  <xsl:call-template name="top-buttons">
+	    <xsl:with-param name="collName" select="$collName"/>
+	    <xsl:with-param name="pageType" select="$pageType"/>
+	  </xsl:call-template>
 	</td>
       </tr>
@@ -133,5 +100,47 @@
     <p/>
   </xsl:template>
-
+  
+  <xsl:template name="top-buttons">
+    <xsl:param name="collName"/>
+    <xsl:param name="pageType"/>
+    <table cellspacing='4'>
+      <tr>
+	<td class="gsbutton">
+	  <a class="gsbutton" 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>
+	</td>
+	<xsl:choose>
+	  <xsl:when test="$pageType='help'">
+	    <td class="gsbuttonoff">
+	      <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
+	    </td>
+	  </xsl:when>
+	  <xsl:otherwise>
+	    <td class="gsbutton">
+	      <a class="gsbutton" 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>
+	    </td>
+	  </xsl:otherwise>
+	</xsl:choose>
+	<xsl:choose>
+	  <xsl:when test="$pageType='pref'">
+	    <td class="gsbuttonoff">
+	      <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
+	    </td>
+	  </xsl:when>
+	  <xsl:otherwise>
+	    <td class="gsbutton">
+	      <a class="gsbutton" 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>
+	    </td>
+	  </xsl:otherwise>
+	</xsl:choose>
+      </tr>
+    </table>
+    
+  </xsl:template>
 
   <xsl:template name="navigationBar">
@@ -168,5 +177,4 @@
       </xsl:otherwise>
     </xsl:choose>
-    <br/>
   </xsl:template>
   
