forrest-svn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thors...@apache.org
Subject svn commit: r496144 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml
Date Sun, 14 Jan 2007 20:47:39 GMT
Author: thorsten
Date: Sun Jan 14 12:47:38 2007
New Revision: 496144

URL: http://svn.apache.org/viewvc?view=rev&rev=496144
Log:
Allowing plugins to provide tiles.
Grouping solr releated contracts to a tiles. The jx:set var="userAgent" must be defined in
the main structurer
and cannot go into a tiles! 
Use <jx:set var="userAgent" value="${cocoon.request.getHeader('User-Agent')}"/>

Added:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml
  (with props)

Added: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml?view=auto&rev=496144
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml
(added)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml
Sun Jan 14 12:47:38 2007
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<forrest:template xmlns:forrest="http://apache.org/forrest/templates/1.0"
+  xmlns:jx="http://apache.org/cocoon/templates/jx/1.0">
+  <!-- default plugin CSS -->
+    <forrest:contract name="branding-css-links">
+      <forrest:property name="branding-css-links-input">
+        <css url="solr.css" media="screen" theme="Pelt"/>
+      </forrest:property>
+    </forrest:contract>
+    <!-- In static mode solr-add allows you to update a Solr server with the content of
your
+        website at the same time you generate the site. -->
+    <forrest:contract name="solr-add">
+      <forrest:property name="request">#{$getRequest}</forrest:property>
+    </forrest:contract>
+    <forrest:hook name="solr">
+      <forrest:hook class="solrSearch">
+      <!--Search interface (solr-search contract) to
+        search your solr server. -->
+        <forrest:contract name="solr-search">
+          <forrest:property name="contextPath">#{$contextPath}</forrest:property>
+          <forrest:property name="hidden">
+            <input name="hl" type="hidden" value="true"/>
+            <input name="hl.fl" type="hidden" value="content"/>
+            <input name="fl" type="hidden" value="id,title"/>
+            <input name="indent" type="hidden" value="on"/>
+            <input name="rows" type="hidden" value="10"/>
+            <input name="start" type="hidden" value="0"/>
+          </forrest:property>
+        </forrest:contract>
+      </forrest:hook>
+      <!-- HEADSUP 
+        The jx:set var="userAgent" must be defined in the main structurer
+        and cannot go into a tiles. -->
+      <!--<jx:set var="userAgent" value="${cocoon.request.getHeader('User-Agent')}"/>-->
+      <!-- If the userAgent is the cocoon crawler then we do not want to 
+      output the actionbar. The cocoon crawler does not provide the request
+      header "User-Agent".-->
+      <jx:if test="${!userAgent.equals('')&amp;null!=userAgent}">
+        <forrest:hook class="solrActionbar">
+        <!-- GUI to manage your project in solr. -->
+          <forrest:contract name="solr-actionbar">
+            <forrest:property name="request">#{$getRequest}</forrest:property>
+            <forrest:property name="contextPath">
+              #{$contextPath}</forrest:property>
+          </forrest:contract>
+        </forrest:hook>
+      </jx:if>
+    </forrest:hook>
+</forrest:template>
\ No newline at end of file

Propchange: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.solr/resources/themes/common/html/solrbar.vt.xml
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message