You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by an...@apache.org on 2007/11/02 12:00:40 UTC

svn commit: r591298 [3/37] - in /lenya/sandbox/pubs/docu/content/authoring: 0033e320-8731-11dc-ae46-9e7b5d14892d/ 003a4bc0-8731-11dc-ae46-9e7b5d14892d/ 018a9980-8731-11dc-ae46-9e7b5d14892d/ 02f9e0f0-8731-11dc-ae46-9e7b5d14892d/ 043dd2a0-8731-11dc-ae46-...

Modified: lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Custom Resource Type</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799888.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799888.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799888.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799888.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Custom Resource Type</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/06bf9b80-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910799888" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770431"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781622343" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781611247"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.1193910792268.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.1193910792268.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.1193910792268.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.1193910792268.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: index.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>Adding a Mime Type How-To</title>
+  </header>
+    <body>
+
+<p>Lenya comes with many mime types supported "off-the-shelf". However the list of mime types is not (and can not be) exhaustive. 
+If you have a Mime-Type which is not yet known to Lenya, such as Avi Videos (Mime-type video/x-msvideo) that the content editors of your site insist on using, proceed as described here. </p>
+
+<section>
+<title id="head-a4bbfe45a08bfc3cc5d0cd1bcfff7fa83460fca6">Enabling the downloads</title>
+
+<p>The resource types which are known to your Lenya installation are defined in the file <em>lenya/resources.xmap</em>. Add the new Mime-Type in here, for example for AVI this is:  
+</p>
+<source xml:space="preserve">
+          &lt;map:match pattern="*/*/**.avi"&gt;
+            &lt;map:read src="pubs/{1}/resources/{2}/{3}.avi" mime-tyoe="video/x-msvideo" /&gt;
+          &lt;/map:match&gt;
+
+</source>
+<p>You probably need to restart your servlet container in order for the changes to take effect. </p>
+<p>Now, visitors of your pages should be able to download objects of this mime-type. </p>
+</section>
+<section>
+<title id="head-c0a473eaffabfbcc5c34cdb6c5efff7ab9e5b7f4">Enabling uploading for content editors</title>
+
+<p>In the asset handling, there are some restrictions as to what filetypes you are allowed to upload. If the file extension you require is not yet allowed, 
+edit the file <em>xslt/authoring/asset.xsl</em> and add it to the list of types defined in <em> &lt;xsl:param name="extensions" ...</em> </p>
+
+<p>If you are using BXE, edit the file <em>xslt/bxeng/asset.xsl</em> and add it to the list of types defined in <em>&lt;xsl:param name="extensions" ...</em> </p>
+</section>
+</body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Adding Mime Types</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792268.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792268.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792268.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792268.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Adding Mime Types</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/07f6bbf0-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910792268" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910765287"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781617821" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781605278"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.1193910778868.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.1193910778868.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.1193910778868.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.1193910778868.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,252 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: index.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>Site Navigation How-To</title>
+  </header>
+    <body>
+<p>One of the ingredients for a good website is a well structured navigation. The Default publication in Lenya comes with a <a href="lenya-document:26cabb80-8731-11dc-ae46-9e7b5d14892d">navigation framework</a> that is made up of horizontal tabs, breadcrumbs and a menu on the left. A lot of websites use these navigational elements, but depending on the site you're building, you might want to change the navigation or structure if differently. </p>
+
+<section>
+<title id="head-da34b3ca6421ef687314b2fc0830c891b3cfa8d7">Technical Background: How Lenya builds the site navigation</title>
+
+<p>The source of all navigation elements is the sitetree, which you can find in <em>PUB_HOME/authoring/sitetree.xml</em>, <em>PUB_HOME/live/sitetree.xml</em>, <em>PUB_HOME/trash/sitetree.xml</em> or <em>PUB_HOME/archive/sitetree.xml</em> depending on the relevant area. </p>
+<p>The tree you can see in the left half of the screen when you access the <em>Site</em> tab in authoring mode is pretty much a 1:1 representation of the site tree. </p>
+
+<p>The sitetree.xml document of the default publication which we will use as an example here looks like this: </p>
+
+<source xml:space="preserve">
+&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;site i18n:attr="label" label="Authoring"
+    xmlns="http://apache.org/cocoon/lenya/sitetree/1.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation=
+        "http://apache.org/cocoon/lenya/sitetree/1.0
+        ../../../../resources/entities/sitetree.xsd"
+    xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+&gt;
+
+  &lt;node id="index"&gt;
+    &lt;label xml:lang="en"&gt;Home&lt;/label&gt;
+
+    &lt;label xml:lang="de"&gt;Home&lt;/label&gt;
+  &lt;/node&gt;
+
+  &lt;node id="tutorial"&gt;
+    &lt;label xml:lang="en"&gt;Tutorial&lt;/label&gt;
+
+    &lt;label xml:lang="de"&gt;Tutorial&lt;/label&gt;
+
+    &lt;node id="new_doctype"&gt;
+      &lt;label xml:lang="en"&gt;Create new doctype&lt;/label&gt;
+    &lt;/node&gt;
+
+  &lt;/node&gt;
+
+  &lt;node id="concepts"&gt;
+    &lt;label xml:lang="en"&gt;Concepts (english only)&lt;/label&gt;
+  &lt;/node&gt;
+
+  &lt;node id="features"&gt;
+
+    &lt;label xml:lang="en"&gt;Features&lt;/label&gt;
+    &lt;label xml:lang="de"&gt;Funktionen&lt;/label&gt;
+  &lt;/node&gt;
+
+  &lt;node id="doctypes"&gt;
+
+    &lt;label xml:lang="en"&gt;Document Type Examples&lt;/label&gt;
+    &lt;label xml:lang="de"&gt;Dokumenttyp Beispiele&lt;/label&gt;
+     &lt;node id="xhtml-document"&gt;
+      &lt;label xml:lang="en"&gt;XHTML Doctype&lt;/label&gt;
+
+      &lt;label xml:lang="de"&gt;XHTML Dokumenttyp&lt;/label&gt;
+    &lt;/node&gt;
+ &lt;/node&gt;
+
+&lt;/site&gt;
+</source>
+<p>The default publication defines three navigation elements: </p>
+
+<ul>
+<li>
+<p> Tabs (horizontal) </p>
+</li>
+<li>
+<p> Breadcrumbs </p>
+</li>
+<li>
+<p> Menu (left) </p>
+</li>
+</ul>
+<p>Each of them is built by applying a specific XSLT to sitetree.xml (compare: <a href="lenya-document:26cabb80-8731-11dc-ae46-9e7b5d14892d">navigation framework</a>). </p>
+
+<p>In case you need additional navigation elements besides tabs, breadcrumbs and menus, you can set up an additional XSLT file and integrate it into the sitemap. (More on this later.) </p>
+
+</section>
+<section>
+<title id="head-07624a224de9bea81634763b7f1dce088cb62439">Tabs as main navigation, menubar as sub-navigation</title>
+
+<p>Depending on the amount of content on your site, you may opt for different styles of navigation. You might for example get rid of the tabs and only use the menu on the left. You can also use the tabs and the menu as parallel means of navigation, which is what the default publication does. If you have a lot of content organized on multiple levels, you might also choose to use the tabs as the first level of navigation and the menu as a second level. </p>
+<p>If your sitetree for example looks like this: </p>
+<p> </p>
+<ul>
+<li>
+<p> Home </p>
+
+</li>
+<li>
+<p> Products </p>
+<ul>
+<li>
+<p> Consumer Products </p>
+<ul>
+<li>
+<p> Product Line A </p>
+</li>
+<li>
+<p> Product Line B </p>
+</li>
+
+<li>
+<p> Product Line C </p>
+</li>
+</ul>
+</li>
+<li>
+<p> Industrial Products </p>
+</li>
+</ul>
+</li>
+<li>
+<p> Services </p>
+<ul>
+<li>
+<p> Maintainance Contracts </p>
+
+</li>
+<li>
+<p> 24-hour Emergency Hotline </p>
+</li>
+</ul>
+</li>
+</ul>
+<p> </p>
+<p>a typical navigation could look this this: </p>
+
+<source xml:space="preserve">
++--------------------------------------------------------------------
+|                       | *HOME* | Products | Services |
++--------------------------------------------------------------------
+|
+</source>
+
+<p>when the user clicks on Producs, a menu will show up: </p>
+
+<source xml:space="preserve">
++--------------------------------------------------------------------
+|                       | Home | *PRODUCTS* | Services |
++--------------------------------------------------------------------
+|
+| - Consumer Products
+| - Industrial Products
+|
+</source>
+<p>clicking on Services will show up a different menu: </p>
+
+<source xml:space="preserve">
+
++--------------------------------------------------------------------
+|                       | Home | Products | *SERVICES* |
++--------------------------------------------------------------------
+|
+| - Maintainance 
+|   Contracts
+| - 24-hour Emergency 
+|   Hotline
+
+</source>
+
+</section>
+<section>
+<title id="head-5180937f0e533c5948230c73f141c9b2c1aecb65">Simple solution: Hide the menus using CSS</title>
+
+<p>This behaviour can be achieved by changing the CSS of the default publication. Edit the file </p>
+
+<source xml:space="preserve">
+$PUB_HOME/resources/shared/css/page.css
+</source>
+<p>and add the following snippet, preferrably beneath the existing <em>menublock</em> declarations: </p>
+
+<source xml:space="preserve">
+.menublock-1 {
+    display: none;
+}
+</source>
+<p>This way, all non-selected first level menu entries are hidden, which comprises all menu entries belonging to the other tabs. </p>
+
+</section>
+<section>
+<title id="head-f6b2dc82fbfce6cdd76a5552ee76fcdd6fd55d53">Advanced solution: Exclude the menus using XSLT</title>
+
+<p>In this approach, you use a custom XSLT stylesheet to generate the menubar XHTML snippet. The file has to be placed at </p>
+
+<source xml:space="preserve">
+$PUB_HOME/lenya/xslt/navigation/menu.xsl
+</source>
+<p>Note the step <em>/lenya</em> in the path, this is necessary to tell Lenya that you're overriding a file from the core. The stylesheet might look as follows: </p>
+
+<source xml:space="preserve">
+
+&lt;xsl:stylesheet version="1.0"
+    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+    xmlns:nav="http://apache.org/cocoon/lenya/navigation/1.0"
+    xmlns="http://www.w3.org/1999/xhtml"
+    exclude-result-prefixes="nav"
+    &gt;
+
+  &lt;xsl:import href="../../../../../xslt/navigation/menu.xsl"/&gt;
+
+  &lt;xsl:template match="nav:site/nav:node[not(descendant-or-self::nav:node[@current = 'true'])]"/&gt;
+
+  &lt;xsl:template match="nav:site/nav:node[descendant-or-self::nav:node[@current = 'true']]"&gt;
+    &lt;div class="menublock-selected-{count(ancestor-or-self::nav:node)}"&gt;
+
+      &lt;xsl:apply-templates select="nav:node"/&gt;
+    &lt;/div&gt;
+  &lt;/xsl:template&gt;
+
+&lt;/xsl:stylesheet&gt; 
+</source>
+<ul>
+<li>
+<p> First, you import the core menu XSL so that you can reuse most of the core functionality. </p>
+
+</li>
+<li>
+<p> The first <em>&lt;xsl:template&gt;</em> excludes all top-level <em>&lt;nav:node&gt;</em> entries which don't contain the current item. </p>
+</li>
+<li>
+<p> The second <em>&lt;xsl:template&gt;</em> is optional. If you include it, the top-level menu items won't be displayed in the menubar. </p>
+
+</li>
+</ul>
+</section>
+</body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Site Navigation</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910778868.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910778868.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910778868.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910778868.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Site Navigation</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/092aa810-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910778868" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910765003"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781621418" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781610161"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.1193910786199.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.1193910786199.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.1193910786199.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.1193910786199.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,174 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2005 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: ldap_authentication.xml 179990 2005-06-04 13:50:15Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>LDAP Authentication How-To</title>
+  </header>
+    <body>
+<p>Lenya supports LDAP authentication out-of-the-box, and was tested with
+  OpenLDAP and MS Active Directory servers.</p>
+
+<p>Authentication means that password checking is handled through LDAP, so
+that the user does not need a Lenya-specific password. Note that only the
+authentication is done through LDAP; the Lenya administrator still has to tell
+Lenya which LDAP users to allow and to assign Lenya roles to these users. LDAP
+setup is handled in Lenya configuration files; adding users and assigning them roles
+is handled within the Lenya Admin GUI. </p>
+
+<section>
+<title id="head-c6473a347c56f380b016b80abd50c11a339f65ba">Configuring and activating LDAP in Lenya</title>
+
+<ol>
+<li>
+<p>Go to the directory <em>lenya/pubs/&lt;your-publication-name&gt;/config/ac</em> </p>
+</li>
+
+<li>
+<p>Edit the file <em>ac.xconf</em> and uncomment the line regarding "LDAP support" </p>
+</li>
+<li>
+<p>Go to the subdirectory <em>passwd</em> and copy the file <em>lenya/pubs/&lt;your-publication-name&gt;/config/ac/passwd/ldap.properties.sample</em> to the file <em>ldap.properties</em> in this directory.  </p>
+
+</li>
+<li>
+<p>Edit the file <em>ldap.properties</em> with your settings (the sample file contains explanations for the entries) </p>
+</li>
+<li>
+<p>Restart your servlet container, so that the changes take effect </p>
+</li>
+<li>
+<p>Login as administrator. In the user's section, you can now add LDAP users: enter the LDAP id, and provide a Lenya id (which may be the same as the LDAP id). Now add group memberships for this id. </p>
+</li>
+<li>
+<p>You should now be able to login with this LDAP user and password. </p>
+</li>
+</ol>
+
+</section>
+<section>
+<title id="head-7a25fa154659dcf977c814cc7e12b6a94861a91e">Allowing LDAP users to work
+with Lenya</title>
+
+<p>Once you have everything configured OK, you can tell Lenya to allow certain LDAP users. It is important to understand that, just because a user exists in LDAP, does not mean she has access to Lenya. The user needs to be explicitly added in Lenya, along with the group memberships. However, the authentication itself (password handling) is then completely handled through LDAP. </p>
+<ol>
+<li>
+<p>In the administration GUI, add the "LDAP user" in order to make this user known to Lenya. You can use the same id for Lenya as the existing LDAP id. </p>
+</li>
+<li>
+<p>Click on the user and add group settings - if user belongs to no groups at all, she will not be able to login </p>
+</li>
+<li>
+<p>Logout and login with the newly created id. </p>
+</li>
+</ol>
+
+</section>
+<section>
+	<title id="head-3d053bed75c60a57241ca53fb6de8c2d45aed024">Going further with LDAP</title>
+
+<p>The LDAP implementation in Lenya is based on the premise that you have an
+existing LDAP directory containing users and passwords, but you do not want to (or are
+not allowed to) add anything particular to Lenya within this LDAP directory,
+such as Lenya roles.</p>
+<p>As a consequence, the Lenya specific user information is <em>not</em>
+stored in LDAP, but instead with the same mechanism as non-LDAP users. What Lenya does
+do for you is delegate authorization (the checking of the user's password in
+LDAP), meaning that the user does not require an additional "Lenya password".</p>
+<p> This implementation of LDAP authentication in Lenya works can be
+replaced by a tighter integration of LDAP, which would possibly provide these advantages:
+</p>
+<ul>
+<li>Maintenance of roles, groups in LDAP as well.
+</li>
+<li>Remove the need to separately enable each LDAP user in Lenya.
+</li>
+</ul>
+<p>
+There is a <a href="http://issues.apache.org/bugzilla/show_bug.cgi?id=34737">patch (nb
+34737)</a> which replaces Lenya's default LDAP handling and fully integrates
+Lenya with an LDAP where users are stored according to the Posix scheme.
+ </p>
+
+</section>
+
+<section>
+<title id="head-066b132fa6e8227f03b8c07a5bc6057717a7564b">Encrypted LDAP</title>
+
+<ul>
+<li>
+<p>  in the file <em>ldap.properties</em>, set <em>security-protocol</em> to the value <em>ssl</em> and set <em>key-store</em> to the name of your keystore file </p>
+</li>
+<li>
+<p> add the LDAP server certificate file to the local keystore using this command: </p>
+</li>
+</ul>
+
+<source xml:space="preserve">
+      keytool -import -keystore .keystore -file &lt;ca_cert_file&gt; -alias &lt;yourdomain.com&gt;
+</source>
+
+</section>
+<section>
+<title id="head-9019cde2979c770be142ebf7a0c6e03dacaf1480">Notes</title>
+
+<ul>
+<li>
+<p> If you modify <em>ldap.properties</em>, it may be necessary to restart your servlet container or at least to reload your webapp in order for the changes to take effect. </p>
+
+</li>
+</ul>
+
+</section>
+<section>
+<title id="head-f1c02c22309913c9392d9f61ac234d4c4b7ed6c3">An example publication using LDAP Authentication: the University of Zurich Lenya Publication</title>
+
+<p>The "University of Zurich Publication" is an example of a publication which uses LDAP authentication. You may wish to install and configure it to authenticate against your LDAP server: this way, you can check whether LDAP authentication is working, before proceeding to activate it in another application. </p>
+<p>Note: this HOW-TO was tested using the "University of Zurich Publication" state on May 26th, 2004. If another version is incompatible with your Lenya installation, don't despair, you will still be able to use the LDAP relevant stuff. </p>
+<ol>
+<li>
+<p>Retrieve the University of Zurich Lenya publications (unitemplate, unizh) described on <a href="http://wyona.org/">http://wyona.org/</a> </p>
+</li>
+
+<li>
+<p>Go to the <em>unitemplate/config/ac/passwd</em> directory and edit <em>ldap.properties</em> as described above </p>
+</li>
+<li>
+<p>if secure LDAP is required, add the server certificate to the keystore as described above </p>
+</li>
+<li>
+<p>Deploy the publications (see <a href="lenya-document:043dd2a0-8731-11dc-ae46-9e7b5d14892d">?</a>Deploy Publication How-To) </p>
+</li>
+
+<li>
+<p>In your browser, refresh your Lenya start page. You should now see, on the left hand side, a link to the "Unitemplate" publication. Login as lenya / levi user and go the Admin area to add a user. </p>
+</li>
+<li>
+<p>Click on "Add University User" (this means LDAP user). In the field "UniAccessID", use the LDAP userid. In the field "CMS User", use the id with which you 
+want to user to log in to Lenya. This may be the same id as for LDAP. </p>
+</li>
+<li>
+<p>Add the desired groups for this user and log out of Lenya. </p>
+</li>
+<li>
+<p>You should now be able to login to Lenya using this new user and his/her LDAP password. </p>
+</li>
+</ol>
+    </section>
+</body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>LDAP Authentication</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910786199.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910786199.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910786199.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910786199.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>LDAP Authentication</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0a5b86f0-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910786199" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770608"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781616447" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781603658"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.1193910801116.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.1193910801116.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.1193910801116.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.1193910801116.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,177 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: index.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>CMS Menus How-To</title>
+  </header>
+    <body>
+<p>The CMS Menus are the menu options in Lenya that are available only in authoring mode and that are used by the editor, reviewer or admin to trigger operations such as editing, deleting or publishing a page and the like. CMS Menus are completely different and have nothing in common with the navigational menus in your publication! </p>
+<p>In other words: The site navigation is what the readers in the Live view will see, while the CMS Menus are only visible in the authoring area. </p>
+
+<section>
+<title id="head-d4956a0675807cf9a821ed7373a9f0ac8b2c4283">Why care about CMS Menus</title>
+
+<p>Most of the time the CMS Menus can be seen as a part of the Lenya application and should just work. But sometimes it will be necessary to introduce additional menu options if your publication has any special operations that need to be accessible through a menu option. Sometimes you might also find that a menu option is grayed out when you think it should be accessible. In that case understanding the anatomy of the CMS menus will help you in debugging the problem. </p>
+
+</section>
+<section>
+<title id="head-8e7bea88bc6cc2c0ef5910f4785f11121b6ebde2">Lenya Core Documentation</title>
+
+<p>There is some information on the CMS Menus in the official Lenya documentation, but it's hidden in a place where you might not expect it. So here's a link: <a href="lenya-document:2a82ba70-8731-11dc-ae46-9e7b5d14892d">Menubar documentation</a> </p>
+<p>Make sure you read that before continuing reading this page here! </p>
+<p>Unfortunately the picture on the page mentioned above is a bit misleading. You might think that "Usecases" and "Workflow" steps in read in the right part of the picture refer to XSLT stylesheets which are applied using the XSLT transformer. This is not the case! They are own transformers implemented directly in the Lenya Java layer: </p>
+
+<source xml:space="preserve">
+    &lt;map:transformer name="workflowmenu" logger="lenya.sitemap.transformer.workflowmenu" src="org.apache.lenya.cms.cocoon.transformation.WorkflowMenuTransformer"/&gt;
+    &lt;map:transformer name="usecasemenu" logger="lenya.sitemap.transformer.usecasemenu" src="org.apache.lenya.cms.cocoon.transformation.UsecaseMenuTransformer"/&gt;
+</source>
+<p>Nevertheless they do exactly what is described in the picture: They disable menu options if they are not accessible because  </p>
+<ul>
+<li>
+<p> executing the usecase requires a role which the user belonging to the current session is lacking or  </p>
+</li>
+<li>
+<p> the current workflow state of the document forbids the usecase </p>
+</li>
+</ul>
+</section>
+<section>
+<title id="head-f06da7765bdcb4fdb7ca94cedada41bafeee1d5b">Introducing a new menu option</title>
+
+<p>First of all, before you start adding a new menu option to the CMS menus, ask yourself what usecase should be linked to that menu option and if the usecase exists already. If you find out that you need a new usecase as well, it is up to you if you first implement the new usecase and test it manually by invoking the appropriate URIs and then add the menu option or do it vice versa. It is just important that you understand that it will take both: The usecase and the menu option to enable new functionality for the user. </p>
+<p>According to the page on the core documentation mentioned above, the CMS menus are defined in an XML document like this: </p>
+
+<source xml:space="preserve">
+&lt;menu
+    xmlns="http://apache.org/cocoon/lenya/menubar/1.0"
+    xmlns:uc="http://apache.org/cocoon/lenya/usecase/1.0"
+    xmlns:wf="http://apache.org/cocoon/lenya/workflow/1.0"&gt;
+
+  ...
+
+  &lt;item wf:event="edit"
+        uc:usecase="edit-forms"
+        uc:step="open" href="?..."&gt;Edit with Forms&lt;/item&gt;
+  
+  ...
+
+
+&lt;/menu&gt;
+</source>
+
+</section>
+<section>
+<title id="head-717f7a242c8db5f6fb81e54e27fcbcf590009452">Edit generic.xsp to add the item for the menu option</title>
+
+<p>In practice this XML is generated of an XSP which you can find in </p>
+<p>
+<em>lenya/pubs/&lt;your-pub&gt;/config/menus/generic.xsp</em> </p>
+<p>Edit this XSP to add your new menu item! </p>
+<p>The XSP is used in the following section of global-sitemap.xmap: </p>
+
+<source xml:space="preserve">
+      &lt;map:match pattern="lenya-page/*/*/**"&gt;
+        &lt;map:generate src="cocoon:/menu-xml/{1}/{2}/{3}"/&gt;
+
+        &lt;map:call resource="i18n"/&gt;
+
+        &lt;map:act type="resource-exists" src="lenya/pubs/{1}/config/workflow/"&gt;
+          &lt;map:transform type="workflowmenu"/&gt;
+
+        &lt;/map:act&gt;
+
+        &lt;map:act type="resource-exists" src="lenya/pubs/{1}/config/ac/usecase-policies.xml"&gt;
+          &lt;map:transform type="usecasemenu"/&gt;
+        &lt;/map:act&gt;
+
+        &lt;map:transform src="lenya/xslt/menu/menu2xhtml.xsl"&gt;
+
+          &lt;map:parameter name="contextprefix" value="{request:contextPath}"/&gt;
+          &lt;map:parameter name="publicationid" value="{1}"/&gt;
+          &lt;map:parameter name="completearea" value="{2}"/&gt;
+          &lt;map:parameter name="documentarea" value="{page-envelope:area}"/&gt;
+          &lt;map:parameter name="documenturl" value="{page-envelope:document-url}"/&gt;
+          &lt;map:parameter name="documentid" value="{page-envelope:document-id}"/&gt;
+
+          &lt;map:parameter name="userid" value="{access-control:user-id}"/&gt;
+          &lt;map:parameter name="servertime" value="{date-i18n:currentDate}"/&gt;
+          &lt;map:parameter name="workflowstate" value="{workflow:state}"/&gt;
+          &lt;map:parameter name="islive" value="{workflow:variable.is_live}"/&gt;
+        &lt;/map:transform&gt;
+
+        &lt;map:call resource="i18n"/&gt;
+
+        &lt;map:transform src="lenya/xslt/menu/menu2xslt.xsl"&gt;
+          &lt;map:parameter name="contextprefix" value="{request:contextPath}"/&gt;
+          &lt;map:parameter name="publicationid" value="{1}"/&gt;
+          &lt;map:parameter name="area" value="{2}"/&gt;
+          &lt;map:parameter name="documenturl" value="{page-envelope:document-url}"/&gt;
+        &lt;/map:transform&gt;
+
+        &lt;map:serialize type="xml"/&gt;
+      &lt;/map:match&gt;
+</source>
+<p>The <em>&lt;map:generate src="cocoon:/menu-xml/{1}/{2}/{3}"/&gt;</em> is an internal pipeline, which can be found in the same file: </p>
+
+<source xml:space="preserve">
+      &lt;!-- menu-xml/{publication-id}/... --&gt;
+
+      &lt;map:match pattern="menu-xml/*/**" internal-only="true"&gt;
+        &lt;map:mount uri-prefix="menu-xml/{1}/" src="lenya/pubs/{1}/menus.xmap" check-reload="true" reload-method="synchron"/&gt;
+      &lt;/map:match&gt;
+</source>
+<p>This mounts the <em>lenya/pubs/&lt;your-pub&gt;/menus.xmap</em> sitemap snippet from the publication which then will decide weather we are in live or authoring mode and generate the menu definition from the publication specific menu.xsp: </p>
+
+<source xml:space="preserve">
+      &lt;map:match pattern="live/**"&gt;
+        &lt;map:generate type="serverpages" src="../../content/menus/live.xsp"/&gt;
+        &lt;map:serialize type="xml"/&gt;
+      &lt;/map:match&gt;
+
+      &lt;map:match pattern="**"&gt;
+
+        &lt;map:generate type="serverpages" src="config/menus/generic.xsp"/&gt;
+        &lt;map:serialize type="xml"/&gt;
+      &lt;/map:match&gt;
+
+    &lt;/map:pipeline&gt;
+</source>
+
+</section>
+<section>
+<title id="head-3c7c7b03da78f976501b3a61c43af692d6ced2c4">Double-check usecase and workflow configuration</title>
+
+<p>If you look back at the <em>lenya-page/*/*/**</em> matcher in global-sitemap.xmap above, the menus are built by: </p>
+<ul>
+<li>
+<p> generating the menu definition from the XSP (which we edited already) </p>
+</li>
+<li>
+<p> applying the workflowmenu and usecasemenu transformers </p>
+</li>
+<li>
+<p> using <em>lenya/xslt/menu/menu2xhtml.xsl</em> to generate the XHTML </p>
+
+</li>
+</ul>
+<p>This means if you added your new menu option to the XSP it should show up in the menu. But it might be grayed out. </p>
+<p>If this is the case, either the workflowmenu or the usecasemneu transformer decided based on the workflow configuration or based on the usecase policy that this option is not available to this user at this point in time. You may want to check the appropriate configurations to check why this is the case. </p>
+<p>The usecase configuration can be found in <em>lenya/pubs/&lt;your-pub&gt;/config/ac/usecase-policies.xml</em> </p>
+</section>   </body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>CMS Menus</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910801116.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910801116.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910801116.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910801116.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>CMS Menus</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0b8adf30-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910801116" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771240"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781624445" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781604004"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.1193910799640.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.1193910799640.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.1193910799640.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.1193910799640.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,225 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: index.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>CMS Screens How-To</title>
+  </header>
+    <body>
+<p>A CMS screen is an HTML page that belongs to the Lenya CMS, not to a specific publication (this is the reason for choosing the term "screen" instead of "page"). Typical examples are site administration screens and confirmation screens.</p>
+
+<section>
+<title id="head-707eb025442a6dfa67ca897b5badaf9dee4fb713">File Locations</title>
+
+<ul>
+<li>
+<p>  <em>src/webapp/lenya/xslt/util/page2xhtml.xsl</em> - The CMS screen stylesheet. </p>
+</li>
+<li>
+<p>  <em>src/webapp/lenya/resources/css</em> - The CMS screen CSS files. </p>
+</li>
+</ul>
+
+</section>
+<section>
+<title id="head-7338ac28444bd3b38e19444cad22202b925f4a69">Sitemap Usage</title>
+
+<p>Usually a resource is used to style a CMS screen: </p>
+
+<source xml:space="preserve">
+&lt;map:resource name="style-cms-page"&gt;
+  &lt;map:transform src="lenya/xslt/util/page2xhtml.xsl"&gt;
+    &lt;map:parameter name="contextprefix"
+                   value="{request:contextPath}"/&gt;
+  &lt;/map:transform&gt;
+
+  &lt;map:serialize/&gt;
+&lt;/map:resource&gt;
+</source>
+<p>¨ This resource is called from the pipeline (the example serves the Lenya CMS starting page): </p>
+
+<source xml:space="preserve">
+&lt;map:match pattern="index.html"&gt;
+  &lt;map:aggregate element="lenya" ...&gt;
+    &lt;map:part src="cocoon:/publications.xml"/&gt;
+
+    &lt;map:part src="lenya/content/introduction.xml"/&gt;
+  &lt;/map:aggregate&gt;
+  &lt;map:transform src="lenya/xslt/util/welcome.xsl"/&gt;
+  &lt;map:call resource="style-cms-page"/&gt;
+&lt;/map:match&gt;
+</source>
+
+</section>
+<section>
+<title id="head-bc001dc9bb21e41435e11b6e1d8d83137c94f57c">Writing a CMS screen</title>
+
+<p>To write a CMS screen, use the following syntax: </p>
+
+<source xml:space="preserve">
+&lt;page:page xmlns:page="http://apache.org/cocoon/lenya/cms-page/1.0"&gt;
+
+  &lt;page:title&gt;
+    &lt;!-- the page title (used for HTML title and heading) --&gt;
+  &lt;/page:title&gt;
+
+  &lt;page:body&gt;
+    &lt;!-- put your XHTML here --&gt;
+  &lt;/page:body&gt;
+
+&lt;/page:page&gt;
+</source>
+
+</section>
+<section>
+<title id="head-1b28e37b4edb357dcda08a8c350c39abee643a31">Cascading Stylesheets</title>
+
+<p>When using CSS classes or IDs, please follow the rule that every class or ID starts with the prefix <em>lenya-</em>. </p>
+<p>Put your specific CSS file in the CSS directory (see above) and include it in <em>default.css</em>. </p>
+<p>Currently, the following Lenya CSS classes are defined: </p>
+<ul>
+<li>
+<p> Boxes </p>
+<ul>
+<li>
+<p>div.lenya-box </p>
+</li>
+<li>
+<p>div.lenya-box-title </p>
+</li>
+<li>
+<p>div.lenya-box-body </p>
+</li>
+</ul>
+</li>
+<li>
+<p> Forms </p>
+<ul>
+<li>
+<p>td.lenya-entry-caption </p>
+</li>
+<li>
+<p>.lenya-form-element </p>
+</li>
+</ul>
+</li>
+<li>
+<p> Tables </p>
+<ul>
+<li>
+<p>table.lenya-table </p>
+</li>
+<li>
+<p>table.lenya-table-noborder </p>
+</li>
+<li>
+<p>table.lenya-table th </p>
+</li>
+<li>
+<p>table.lenya-table td </p>
+</li>
+<li>
+<p>table.lenya-table-noborder td </p>
+</li>
+</ul>
+</li>
+<li>
+<p> Tabs </p>
+<ul>
+<li>
+<p>.lenya-tab </p>
+</li>
+<li>
+<p>.lenya-tablink </p>
+</li>
+</ul>
+
+</li>
+<li>
+<p> Antlog </p>
+<ul>
+<li>
+<p>.lenya-ant-bannercell </p>
+</li>
+<li>
+<p>table.lenya-ant-status </p>
+</li>
+<li>
+<p>.lenya-ant-error </p>
+</li>
+<li>
+<p>.lenya-ant-warn </p>
+</li>
+<li>
+<p>.lenya-ant-info </p>
+</li>
+<li>
+<p>.lenya-ant-debug </p>
+</li>
+<li>
+<p>.lenya-ant-failed </p>
+</li>
+<li>
+<p>.lenya-ant-complete </p>
+</li>
+<li>
+<p>.lenya-ant-a td </p>
+</li>
+<li>
+<p>.lenya-ant-b td </p>
+</li>
+</ul>
+</li>
+<li>
+<p> Misc </p>
+<ul>
+<li>
+<p>.lenya-body </p>
+</li>
+<li>
+<p>.lenya-project-logo </p>
+</li>
+<li>
+<p>td.lenya-content </p>
+</li>
+<li>
+<p>td.lenya-sidebar </p>
+</li>
+<li>
+<p>td.lenya-frontpage </p>
+</li>
+<li>
+<p>.lenya-page-title </p>
+</li>
+<li>
+<p>.lenya-page-subtitle </p>
+</li>
+<li>
+<p>.lenya-publication-item </p>
+</li>
+<li>
+<p>.lenya-sidebar a </p>
+</li>
+<li>
+<p>.lenya-sidebar-heading </p>
+</li>
+</ul>
+</li>
+</ul>
+</section>   </body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>CMS Screens</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799640.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799640.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799640.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910799640.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>CMS Screens</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0cc3fb70-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910799640" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770244"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781625625" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781605090"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.1193910787206.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.1193910787206.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.1193910787206.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.1193910787206.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,197 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 1.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-1.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: index.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>Searching Publications How-To</title>
+  </header>
+    <body>
+    <section>
+<title>Introduction</title>
+            <p>This article has 4 goals:</p>
+            <ol>
+            <li>Complete instructions for indexing on Windows.</li>
+            <li>Display search with a publication's layout rather than the global layout.</li>
+            <li> Filter out a Member's Only area from the results.</li>
+            <li> Fix poor design decisions and bugs.</li>
+            </ol>
+            <p>Changes include:</p>
+            <ol>
+            <li> Index live XML files.<br/>The standard method crawls the site, putting the results into the  "htdocs_dump" directory. The index is built from there. The index will not include documents not accessible from the start page, such as Members' Only sections. The index also include navigation menus.<br/>Using the XML files indexes all content, whether accessible or not, and does not index the site architecture. If a visitor searches on "search", they should receive documents including the word "search", not every page with the search function (which should be every page in a well-designed website).<br/>The index still includes everything in a document including header information such as author. It is easy to limit the index to the content body, but that could cause complications when using non-standard Lenya documents (Custom DocTypes/Resource Types). If Custom Doctypes are used, modify searchfixer.xsl (see below). <strong>Custom Doctypes were not tested with thi
 s configuration.</strong>
+</li>
+            
+            <li> Remove "Members' Only" documents if not authorized. Visitors must be logged in and in one of the specified Goups. It is the reverse of the current Lenya security, since deep URLs must pass the test for all parents. Example: /employees/programmers must pass tests for both the "/employees" and "/employees/programmers" sections.</li>
+            
+            <li> Add language to the index.</li>
+            <li> Limit initial search to current language.</li>
+            <li> Search page: Remove choice of publications. (This is a design decision. One publication = one website. With protected areas, there should be no need for multiple publications.)</li>
+            <li> Search page: Filter by chosen languages.</li>
+            <li> Default to search "Content", not "Title".</li>
+            <li> Increase the default results per page from 3 to 10.</li>
+</ol>
+            
+            <p>NOTE: Replace {pub} with your publication name in all instructions.</p>
+            </section>
+            <section>
+<title>Indexing on Windows</title>
+            <p>This assumes Lenya 1.2.2 was installed to C:\apache-lenya-1.2.2 If your installation is different, adjust the paths. The indexer adds namespaces to the data of Fields in the index. The namespaces are not used (and are annoying), so remove them. An alternative is to fix the XML later, but why bother? File: <em>C:\apache-lenya-1.2.2\build\lenya\webapp\WEB-INF\classes\org\apache\lenya\lucene\index\configuration2xslt.xsl</em> Add the following line:</p>
+            <source xml:space="preserve">&lt;xsl:template match="namespace"/&gt;</source>
+            <ol>
+<li>Set the configuration by changing: <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\config\search\lucene-live.xconf</em>
+            To:
+            <source xml:space="preserve">
+            &lt;?xml version="1.0"?&gt;
+             &lt;lucene&gt;
+                 &lt;update-index type="new"/&gt;
+                 &lt;index-dir src="../../work/search/lucene/index/live/index"/&gt;
+                 &lt;htdocs-dump-dir src="../../content/live"/&gt;
+                 &lt;indexer class="org.apache.lenya.lucene.index.ConfigurableIndexer"&gt;
+                     &lt;configuration src="lenyadocs.xconf"/&gt;
+                     &lt;extensions src="xml"/&gt;
+                 &lt;/indexer&gt;
+             &lt;/lucene&gt;</source>
+</li>
+            <li> Create a new file in the same directory to tell lucene what fields to index (filename must match the configuration src in lucene-live.xconf): <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\config\search\lenyadocs.xconf</em>
+            Add this:
+            <source xml:space="preserve">&lt;?xml version="1.0"?&gt;
+             &lt;luc:document xmlns:luc="http://apache.org/cocoon/lenya/lucene/1.0"&gt;
+             &lt;luc:field name="title" type="Text"&gt;
+                 &lt;namespace prefix="lenya"&gt;http://apache.org/cocoon/lenya/page-envelope/1.0&lt;/namespace&gt;
+                 &lt;namespace prefix="dc"&gt;http://purl.org/dc/elements/1.1/&lt;/namespace&gt;
+                 &lt;xpath&gt;/*/lenya:meta/dc:subject&lt;/xpath&gt;
+             &lt;/luc:field&gt;
+             &lt;luc:field name="htmltitle" type="Text"&gt;
+                 &lt;namespace prefix="xhtml"&gt;http://www.w3.org/1999/xhtml&lt;/namespace&gt;
+                 &lt;xpath&gt;/xhtml:html/xhtml:head/xhtml:title&lt;/xpath&gt;
+             &lt;/luc:field&gt;
+             &lt;luc:field name="language" type="Text"&gt;
+                 &lt;namespace prefix="lenya"&gt;http://apache.org/cocoon/lenya/page-envelope/1.0&lt;/namespace&gt;
+                 &lt;namespace prefix="dc"&gt;http://purl.org/dc/elements/1.1/&lt;/namespace&gt;
+                 &lt;xpath&gt;/*/lenya:meta/dc:language&lt;/xpath&gt;
+             &lt;/luc:field&gt;
+             &lt;luc:field name="description" type="Text"&gt;
+                 &lt;namespace prefix="lenya"&gt;http://apache.org/cocoon/lenya/page-envelope/1.0&lt;/namespace&gt;
+                 &lt;namespace prefix="dc"&gt;http://purl.org/dc/elements/1.1/&lt;/namespace&gt;
+                 &lt;xpath&gt;/*/lenya:meta/dc:description&lt;/xpath&gt;
+             &lt;/luc:field&gt;
+             &lt;luc:field name="htmlbody" type="Text"&gt;
+                 &lt;namespace prefix="xhtml"&gt;http://www.w3.org/1999/xhtml&lt;/namespace&gt;
+                 &lt;xpath&gt;/xhtml:html/xhtml:body&lt;/xpath&gt;
+             &lt;/luc:field&gt;
+             &lt;luc:field name="contents" type="UnStored" xpath="/"/&gt;
+             &lt;/luc:document&gt;</source>
+            </li>
+            <li> Create a batch file: <em>C:\apache-lenya-1.2.2\tools\bin\Index-{pub}.bat</em> With this:
+            <source xml:space="preserve">
+             SET LENYAPUB={pub}
+             SET CLASSPATH=.
+             SET ANT_HOME=C:\apache-lenya-1.2.2\tools
+             ant -f ../../build/lenya/webapp/lenya/bin/crawl_and_index.xml
+            -Dlucene.xconf=../../build/lenya/webapp/lenya/pubs/%LENYAPUB%/config/search/lucene-live.xconf
+            index</source>
+            </li>
+            
+            <li> To create a logfile (and avoid some ant errors), create a file: <em>C:\apache-lenya-1.2.2\tools\bin\log4j.properties</em> With this:
+            <source xml:space="preserve">
+             log4j.rootLogger=INFO, lucene
+             log4j.appender.lucene = org.apache.log4j.FileAppender
+             log4j.appender.lucene.File = lucene.log
+             log4j.appender.lucene.Append = false
+             log4j.appender.lucene.layout = org.apache.log4j.PatternLayout
+             log4j.appender.lucene.layout.ConversionPattern = %d{ABSOLUTE} [%t] %-5p
+            %-30.30c{2} %x - %m %n</source>
+            </li>
+            
+            <li> Quit Lenya (to avoid file-locking issues). Run the batch file. Check the  log.The index created works, but the results are not formatted properly.</li>
+            <li> "sitemap.xml" may appear.</li>
+            <li> All links are wrong. They have an extra slash and "/index_xx.xml" must be changed to ".html".</li>
+            <li> The excerpt is not available and displays a Java error.</li>
+            <li>These are fixed in the next section.</li>
+</ol>
+            
+            </section>
+<section>
+<title>Fix the XML results to be usable.</title>
+            <p>Copy <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\xslt\search\sort.xsl</em> To: <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\lenya\xslt\search\sort.xsl</em>. Copy <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\xslt\navigation\search.xsl</em>
+            to <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\lenya\xslt\navigation\search.xsl</em>
+            After the other params, add this line:</p>
+            <source xml:space="preserve">&lt;xsl:param name="chosenlanguage"/&gt;</source>
+            <p>Add the usecase and language fields to the form tag:</p>
+            <source xml:space="preserve">
+            &lt;form&gt;
+                &lt;input type="hidden" name="lenya.usecase" value="search"/&gt;
+                &lt;input type="hidden" name="language" value="{$chosenlanguage}"/&gt;
+                &lt;input class="searchfield" type="text" name="query" alt="Search field"/&gt;
+                &lt;input class="searchsubmit" type="submit" value="Search" name="find"/&gt;
+            &lt;/form&gt;</source>
+            <p>
+<a href="search-and-results.xsp">Download</a> new file: <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\lenya\content\search\search-and-results.xsp</em> Based on <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\content\search\search-and-results.xsp</em>
+</p>
+            <ul>
+            <li>Removed useless information. (I like dynamic lists better than anyone, but Search is a standard function with standard outputs, so why bother? I only left the &lt;fields&gt; tag to separate our output from lucene's.)</li>
+            <li>Added language filter.</li>
+            <li>Added protected section filter.</li>
+            <li>Hardcoded ProtectedUrls. The default is to require visitors be in an  "employee" Group to access "/live/employee". <strong>Configure this for your website.</strong>
+</li>
+            <li>Uses Groups rather than Roles. (Roles are useless as long as "world" inherits "visit" for everything.)</li>
+            <li>Fixed counters and total. (Total-hits changed from property to element of results.)</li>
+           <li>Other bug fixes</li>
+</ul>
+            
+            <p>
+<a href="searchfixer.xsl">Download</a> new file: <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\lenya\xslt\search\searchfixer.xsl</em> This file converts our poor output to something usable.</p>
+            <ul>
+<li>Add languages to configuration</li>
+            <li>Move total-hits from element to property of results.</li>
+            <li>Choose "title" from "htmltitle" or Lucene's "title".</li>
+            <li>Choose "excerpt" from "htmlbody", Lenya's "description", or Lucene's "excerpt"</li>
+            <li>Transform URI from lucene's "uri" (/about/jobs/index_en.xml) to Lenya link (about/jobs_en.html).</li>
+            <li>The default is to use htmlbody for the excerpt. <strong>This file must be modified when using Custom Doctypes that do not have a /html/body.</strong>
+</li>
+            </ul> 
+            <p>
+<a href="usecase-search.xmap">Download</a> new file:
+            <em>C:\apache-lenya-1.2.2\build\lenya\webapp\lenya\pubs\{pub}\usecase-search.xmap</em>
+</p>
+            
+            </section>
+<section>
+<title>Blocking default search.</title>
+           <p> It is important to block the default search when implementing ProtectedAreas to prevent visitors from typing the URL of the default search (or, if this publication was in production, using a bookmark to the old search) and seeing links to protected documents.</p>
+           <ul> 
+            <li> Create new file:  <em>build\lenya\webapp\lenya\pubs\{pub}\lenya\lucene.xmap</em>
+</li>
+            <li>Add content:
+            <source xml:space="preserve">
+             &lt;?xml version="1.0" encoding="UTF-8"?&gt;
+             &lt;map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0"&gt;
+             &lt;map:pipelines&gt;
+                 &lt;map:pipeline&gt;
+                     &lt;map:match pattern="*/search-*/lucene.xml"&gt;
+                         &lt;map:redirect-to uri="/{page-envelope:publication-id}/live/index.html?lenya.usecase=search"/&gt;
+                     &lt;/map:match&gt;
+                     &lt;map:match pattern="*/search-*/lucene*"&gt;
+                         &lt;map:redirect-to uri="/{page-envelope:publication-id}/live/index.html?lenya.usecase=search"/&gt;
+                     &lt;/map:match&gt;
+                 &lt;/map:pipeline&gt;
+             &lt;/map:pipelines&gt;
+             &lt;/map:sitemap&gt;</source>
+</li>
+</ul>
+</section>   </body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Search Publications</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910787206.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910787206.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910787206.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910787206.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Search Publications</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0de9b6c0-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910787206" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771372"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781632411" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781611268"/>
 </XPSRevisionControl>

Added: lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.1193910792084.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.1193910792084.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.1193910792084.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.1193910792084.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: index.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+  <header>
+    <title>Integrating external data How-To</title>
+  </header>
+    <body>
+            <p>This article is about how to pull XML data from another web server and integrate it into a Lenya website.  Your first decision is where Lenya enters your code. There are two good possibilities for your goals:</p>
+<ol>
+            <li>Interrupt before &lt;map:match pattern="**.html"&gt;</li>
+            <li>Interrupt at getting the data.</li>
+</ol>
+            <section>
+<title>First Solution</title>
+            <p>
+            1. Interrupt before &lt;map:match pattern="**.html"&gt;
+            Add a match and write everything needed to create your page.
+            {1} = url before "/people/"
+            {2} = url between "people/" and ".html"</p>
+            <source xml:space="preserve">
+            &lt;map:match pattern="**/people/*.html"&gt;
+                 &lt;map:aggregate element="cmsbody"&gt;
+                     &lt;map:part src="cocoon://navigation/{page-envelope:publication-id}/{page-envelope:area}/breadcrumb/index.xml"/&gt;
+                     &lt;map:part src="cocoon://navigation/{page-envelope:publication-id}/{page-envelope:area}/tabs/index.xml"/&gt;
+                     &lt;map:part src="cocoon://navigation/{page-envelope:publication-id}/{page-envelope:area}/menu/index.xml"/&gt;
+                     &lt;map:part src="cocoon://navigation/{page-envelope:publication-id}/{page-envelope:area}/search/index.xml"/&gt;
+                     &lt;map:part src="cocoon:/people-{2}"/&gt;
+                 &lt;/map:aggregate&gt;
+                 &lt;map:transform src="xslt/page2xhtml-people.xsl"/&gt;
+                 &lt;map:serialize type="xml"/&gt;
+             &lt;/map:match&gt;</source>
+            <p>(You should copy all the code in &lt;map:match pattern="lenyabody-*/*/*/*/**"&gt;.</p>
+             <source xml:space="preserve">
+              &lt;map:match pattern="people-**"&gt;
+                 &lt;map:generate src="http://www.xmlhack.com/cdf.cdf?{1}"/&gt;
+                 &lt;map:transform src="xslt/xmlhack.xsl"/&gt;
+                 &lt;map:serialize type="html"/&gt;
+             &lt;/map:match&gt;</source>
+            <p>Notice I added the filename requested (without an extension) to the querystring of the remote request.</p>
+            </section>
+            <section>
+<title>Second Solution</title>
+            <p>
+            2. Interrupt at getting the data.
+            2.a Set a new doctype in "parameter-doctype.xmap". This code must be before &lt;map:match pattern="*/**.html"&gt;:</p>
+             <source xml:space="preserve">&lt;map:match pattern="**/people/*.html"&gt;
+             &lt;map:generate type="serverpages" src="../../config/parameters/default.xsp"&gt;
+             &lt;map:parameter name="value" value="people"/&gt;
+             &lt;/map:generate&gt;
+             &lt;map:serialize type="xml"/&gt;
+             &lt;/map:match&gt;</source>
+            
+            <p>2.b Get the content from the remote source in "doctypes.xmap". This code must be before &lt;map:match pattern="*/*/*/**.xml"&gt;:
+            {1} = "view"
+            {2} = area
+            {3} = document=path with final ".xml" removed</p>
+             <source xml:space="preserve">
+             &lt;map:match pattern="*/*/people/**.xml"&gt;
+                 &lt;map:generate src="http://www.xmlhack.com/cdf.cdf?{3}"/&gt;
+                 &lt;map:transform src="xslt/people2xhtml.xsl"&gt;
+                     &lt;map:parameter name="rendertype" value="{1}"/&gt;
+                     &lt;map:parameter name="nodeid" value="{page-envelope:document-node-id}"/&gt;
+                     &lt;map:parameter name="language" value="{page-envelope:document-language}"/&gt;
+                 &lt;/map:transform&gt;
+                 &lt;map:serialize type="xml"/&gt;
+             &lt;/map:match&gt;</source>
+            <p>Notice I added the filename requested (without an extension) to the querystring of the remote request.</p>
+
+            <p>2.c Use these filenames for your transformation: <em>xslt/people2xhtml.xsl</em> (Use whatever is specified in 2.b, but this is the standard naming convention.)
+            <em>xslt/page2xhtml-people.xsl</em>  I recommend the second option. It is much less code (less chance of bugs), and takes advantage of Lenya's standards.</p>
+</section>   </body>
+</document>

Modified: lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta Fri Nov  2 03:57:25 2007
@@ -1,11 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <metadata xmlns="http://apache.org/lenya/metadata/1.0">
-<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
-<element key="mimeType">
-<value>application/xml</value>
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>External Data</value>
 </element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
 <element key="extension">
 <value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
 </element>
 <element key="resourceType">
 <value>forrestDocument20</value>

Added: lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792084.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792084.bak?rev=591298&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792084.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.meta.1193910792084.bak Fri Nov  2 03:57:25 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>External Data</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=591298&r1=591297&r2=591298&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/0f158c90-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov  2 03:57:25 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910792084" version="2"/>
+<CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910765078"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781628403" version="1"/>
 <CheckOut identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781608127"/>
 </XPSRevisionControl>



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@lenya.apache.org
For additional commands, e-mail: commits-help@lenya.apache.org