Index: zpt/layer_text_search.zpt
===================================================================
--- zpt/layer_text_search.zpt	(revision 532)
+++ zpt/layer_text_search.zpt	(revision 540)
@@ -17,5 +17,5 @@
       <metal:block metal:define-macro="layer_select_li">
         <li tal:condition="python:query"><input type="checkbox" class="autosubmit" name="viewLayer" value="search"
-          tal:attributes="checked python:'search' in viewLayers" /> Search hits</li>
+          tal:attributes="checked python:'search' in viewLayers" /> Search results</li>
       </metal:block>
     </ul>
@@ -25,6 +25,5 @@
     <!-- right-side search results -->
     <div class="col results" tal:condition="query">
-      <!--"BEGIN SEARCH RESULTS"  -->
-      <div class="options">
+      <div class="result">
         <h4>Search results</h4>
         <div
@@ -33,4 +32,7 @@
           <div class="ruler" tal:define="startParam string:resultStart">
             <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
+          </div>
+          <div class="query">
+            Searching "<span tal:content="query" />" (<span tal:content="queryType" />)
           </div>
           <div class="content"
@@ -42,5 +44,5 @@
 
   <metal:block metal:define-macro="options_box">
-    <!--"BEGIN SEARCH"-->
+    <!-- search options -->
     <div class="options">
       <h4>Search</h4>
@@ -55,5 +57,5 @@
         <!-- query text -->
         <input type="text" name="query" tal:attributes="value query" /> <br /> <input type="submit" value="Search" /> <a
-          tal:attributes="href python:here.getLink('query',None)">Clear</a>
+          tal:condition="query" tal:attributes="href python:here.getLink('query',None)">Clear</a>
         <ul>
           <li><input type="radio" name="queryType" value="fulltext" tal:attributes="checked python:queryType=='fulltext'" />
@@ -68,5 +70,5 @@
       </form>
     </div>
-    <!--"END SEARCH"-->
+    <!-- end search options-->
   </metal:block>
 
Index: zpt/toc_concordance.zpt
===================================================================
--- zpt/toc_concordance.zpt	(revision 539)
+++ zpt/toc_concordance.zpt	(revision 540)
@@ -14,5 +14,5 @@
                 batch python:here.getBatch(start=start,size=grpsize,end=tocsize,data=pageNumbers);">
       <h4>Page concordance</h4>              
-      <div class="ruler">
+      <div class="ruler top">
         <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
       </div>
@@ -36,5 +36,5 @@
         </table>
       </div>
-      <div class="ruler">
+      <div class="ruler bottom">
         <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
       </div>
Index: zpt/toc_figures.zpt
===================================================================
--- zpt/toc_figures.zpt	(revision 539)
+++ zpt/toc_figures.zpt	(revision 540)
@@ -13,10 +13,10 @@
                 batch python:here.getBatch(start=start,size=grpsize,end=tocsize);">
       <h4>Table of figures</h4>
-      <div class="ruler">
+      <div class="ruler top">
         <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
       </div>
       <div class="content"
         tal:content="structure python:here.getTocPage(mode='figures',start=start,pageinfo=pageinfo,docinfo=docinfo)" />
-      <div class="ruler">
+      <div class="ruler bottom">
         <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
       </div>
Index: zpt/toc_text.zpt
===================================================================
--- zpt/toc_text.zpt	(revision 539)
+++ zpt/toc_text.zpt	(revision 540)
@@ -13,9 +13,9 @@
     <div class="tocbody text">
       <h4>Table of contents</h4>
-      <div class="ruler">
+      <div class="ruler top">
         <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
       </div>
       <div class="content" tal:content="structure python:here.getTocPage(mode='text',start=start,pageinfo=pageinfo,docinfo=docinfo)" />
-      <div class="ruler">
+      <div class="ruler bottom">
         <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler" />
       </div>
Index: zpt/toc_thumbs.zpt
===================================================================
--- zpt/toc_thumbs.zpt	(revision 539)
+++ zpt/toc_thumbs.zpt	(revision 540)
@@ -20,5 +20,5 @@
       <div class="content">
         <h4>List of thumbnails</h4>
-        <div class="ruler">
+        <div class="ruler top">
           <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler_thumbs" />
         </div>
@@ -35,5 +35,5 @@
           </tr>
         </table>
-        <div class="ruler">
+        <div class="ruler bottom">
           <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler_thumbs" />
         </div>
Index: zpt/viewer_images.zpt
===================================================================
--- zpt/viewer_images.zpt	(revision 538)
+++ zpt/viewer_images.zpt	(revision 540)
@@ -59,8 +59,8 @@
       <!-- col-main: text page -->
       <div class="col main">
-        <div class="ruler">
+        <div class="ruler top">
           <metal:block metal:use-macro="here/template/common_template/macros/page_ruler" />
         </div>
-        <div class="content-images">
+        <div class="content images">
           <div id="scaler">
             <img tal:attributes="src string:${docinfo/imageURL}&pn=${pageinfo/pn}&dw=500&dh=500" />
Index: zpt/viewer_index.zpt
===================================================================
--- zpt/viewer_index.zpt	(revision 539)
+++ zpt/viewer_index.zpt	(revision 540)
@@ -23,5 +23,5 @@
     <div class="col index-image">
       <!-- image -->
-      <a tal:define="tp docinfo/titlePage | nothing"
+      <a tal:define="tp docinfo/titlePage | string:1"
         tal:attributes="href python:context.getLink(params={'viewMode':'auto','pn':tp})"><img tal:condition="tp" border="0"
         tal:attributes="src string:${docinfo/imageURL}&pn=$tp&dw=300&dh=500" /><img
@@ -68,31 +68,39 @@
 
         <tal:block tal:define="dri docinfo/DRI | nothing" tal:condition="dri">
-        <h2>Permanent URL</h2>
-        <table>
-          <tr>
-            <td class="type">Document ID:</td>
-            <td class="content" tal:content="dri" />
-          </tr>
-          <tr>
-            <td class="type">Permanent URL:</td>
-            <td class="content"><a tal:attributes="href string:http://echo.mpiwg-berlin.mpg.de/$dri"
-              tal:content="string:http://echo.mpiwg-berlin.mpg.de/$dri" /></td>
-          </tr>
-        </table>
+          <h2>Permanent URL</h2>
+          <table>
+            <tr>
+              <td class="type">Document ID:</td>
+              <td class="content" tal:content="dri" />
+            </tr>
+            <tr>
+              <td class="type">Permanent URL:</td>
+              <td class="content"><a tal:attributes="href string:http://echo.mpiwg-berlin.mpg.de/$dri"
+                tal:content="string:http://echo.mpiwg-berlin.mpg.de/$dri" /></td>
+            </tr>
+          </table>
         </tal:block>
 
         <tal:block tal:define="attribution docinfo/attribution | nothing; copyright docinfo/copyright | nothing">
-        <h2>Copyright information</h2>
-        <table border="0" tal:condition="attribution | copyright">
-          <!-- attribution -->
-          <tr tal:condition="attribution"
-            tal:replace="structure python:here.metadataService.getAttributionFormatted('metadata_template', data=attribution)" />
-          <!-- copyright -->
-          <tr tal:condition="copyright"
-            tal:replace="structure python:here.metadataService.getCopyrightFormatted('metadata_template', data=copyright)" />
-        </table>
-        <table border="0" tal:condition="not:attribution | copyright">
-          <tr><td></td></tr>
-        </table>        
+          <h2>Copyright information</h2>
+          <table border="0" tal:condition="attribution | copyright">
+            <!-- attribution -->
+            <tr tal:condition="attribution"
+              tal:replace="structure python:here.metadataService.getAttributionFormatted('metadata_template', data=attribution)" />
+            <!-- copyright -->
+            <tr tal:condition="copyright"
+              tal:replace="structure python:here.metadataService.getCopyrightFormatted('metadata_template', data=copyright)" />
+          </table>
+          <table border="0" tal:condition="not:attribution | copyright">
+            <tr>
+              <td class="type">Copyright:</td>
+              <td class="content"><a target="_blank" href="http://www.mpiwg-berlin.mpg.de">Max Planck Institute for the
+                  History of Science</a> (unless otherwise stated)</td>
+            </tr>
+            <tr>
+              <td class="type">License:</td>
+              <td class="content"><a href="http://creativecommons.org/licenses/by-sa/3.0/de/">CC-BY-SA</a></td>
+            </tr>
+          </table>
         </tal:block>
       </div>
@@ -107,12 +115,19 @@
             target="_blank">&#8594;HTML</a> or <a
             tal:attributes="href python:'http://mpdl-system.mpiwg-berlin.mpg.de/mpdl/getDoc?doc=%s'%(docpath)" target="_blank">&#8594;XML</a>
+          (copyright and license see above)
         </div>
         <div class="action">
           <!--BEGIN search -->
-          <form tal:condition="docpath" tal:attributes="action python:here.getLink()">
+          <form tal:define="queryType string:fulltextMorph" tal:condition="docpath" tal:attributes="action python:here.getLink()">
             <input type="hidden" tal:define="params python:here.getParams('viewMode', None)" tal:repeat="param params"
-              tal:attributes="name param; value python:params[param]" /> <input class="textMain" name="query"
-              onfocus="this.select();" type="text" tal:attributes="value query" /> <input type="submit" class="buttonMain"
-              value="Search in Book" />
+              tal:attributes="name param; value python:params[param]" /> <input type="hidden" name="viewLayer" value="search" />
+            <!-- query text -->
+            <input type="text" name="query" tal:attributes="value query" /> <input type="submit" value="Search full document" /> <a
+              tal:condition="query" tal:attributes="href python:here.getLink('query',None)">Clear</a><br /> <input type="radio"
+              name="queryType" value="fulltext" tal:attributes="checked python:queryType=='fulltext'" /> Exact <input type="radio"
+              name="queryType" value="fulltextMorph" tal:attributes="checked python:queryType=='fulltextMorph'" /> All forms <input
+              type="radio" name="queryType" value="ftIndex" tal:attributes="checked python:queryType=='ftIndex'" /> Fulltext index
+            <input type="radio" name="queryType" value="ftIndexMorph" tal:attributes="checked python:queryType=='ftIndexMorph'" />
+            Morphological index
           </form>
           <!-- END search-->
Index: zpt/viewer_text.zpt
===================================================================
--- zpt/viewer_text.zpt	(revision 536)
+++ zpt/viewer_text.zpt	(revision 540)
@@ -52,8 +52,8 @@
       <!-- text page -->
       <div class="col main">
-        <div class="ruler">
+        <div class="ruler top">
           <metal:block metal:use-macro="here/template/common_template/macros/page_ruler" />
         </div>
-        <div class="content">
+        <div class="content text">
           <div class="pageHeaderTitle" tal:condition="exists:pageinfo/pageHeaderTitle"
             tal:content="structure pageinfo/pageHeaderTitle" />
Index: zpt/viewer_thumbs.zpt
===================================================================
--- zpt/viewer_thumbs.zpt	(revision 536)
+++ zpt/viewer_thumbs.zpt	(revision 540)
@@ -59,8 +59,7 @@
           </table>
         </div>
-        <div class="ruler down">
+        <div class="ruler bottom">
           <metal:block metal:use-macro="here/template/common_template/macros/toc_ruler_thumbs" />
         </div>
-
       </div>
       <!-- /col-main -->
Index: zpt/viewer_xml.zpt
===================================================================
--- zpt/viewer_xml.zpt	(revision 532)
+++ zpt/viewer_xml.zpt	(revision 540)
@@ -43,8 +43,8 @@
       <!-- text page -->
       <div class="col main">
-        <div class="ruler">
+        <div class="ruler top">
           <metal:block metal:use-macro="here/template/common_template/macros/page_ruler" />
         </div>
-        <div class="content">
+        <div class="content xml">
           <div class="pageHeaderTitle" tal:condition="exists:pageinfo/pageHeaderTitle"
             tal:content="structure pageinfo/pageHeaderTitle" />
