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/16 16:12:50 UTC

svn commit: r595691 [5/28] - in /lenya/sandbox/pubs/docu: config/ content/authoring/ content/authoring/0033e320-8731-11dc-ae46-9e7b5d14892d/ content/authoring/018a9980-8731-11dc-ae46-9e7b5d14892d/ content/authoring/02f9e0f0-8731-11dc-ae46-9e7b5d14892d/...

Added: lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906836.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906836.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906836.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906836.bak Fri Nov 16 07:11:58 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>HTML Form Editor</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/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221906836" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221886113"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910780940" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910766337"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781628433" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.1195221907270.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.1195221907270.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.1195221907270.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.1195221907270.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,63 @@
+<?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: 1form.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>HTML One Form Editor</title>
+     
+     
+     
+</header> 
+<body> 
+
+<section>
+<title>Integration</title>
+<p>In order to make an XML document editable by the One Form Editor, one needs to add a menu item as follows:</p>
+<source xml:space="preserve">
+<![CDATA[
+  <menus>
+    <menu name="File" label="File">
+      <block>
+        <item uc:usecase="1formedit" href="?lenya.step=open">Edit&#160;with&#160;one&#160;Form</item>
+        ...
+]]>
+</source>
+<p>
+Note that the filesystem path is generated by the path mapper which is configured within <code>pub-id/config/publication.xconf</code>.
+</p>
+<p>
+In order to get the redirect right after closing and saving the document, one might need to add a <code>redirect-to</code> entry to the publication specific sitemap.
+</p>
+</section>
+
+<section>
+<title>Configuration</title>
+<p>
+The One Form Editor can be configured within the generic Lenya usecase sitemap <code>lenya/usecase.xmap</code>.
+</p>
+</section>
+
+<section>
+<title>Validation</title>
+<p>
+Upon saving, the form content is validated against the appropriate Relax NG schema using the <code>ValidateAction</code>
+</p>
+</section>
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907270.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907270.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907270.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907270.bak Fri Nov 16 07:11:58 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>HTML One Form Editor</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/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/21c83b30-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221907270" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221886855"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910787887" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771675"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781625569" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.1195221908676.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.1195221908676.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.1195221908676.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.1195221908676.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,260 @@
+<?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: bxe.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>Bitflux Editor (BXE)</title>
+     
+     
+     
+</header> 
+<body> 
+
+<section>
+<title>Overview</title>
+<p>
+<a href="http://bxe.oscom.org">BXE</a> is a validating WYSIWYG XML editor for Mozilla-based browsers.
+    It uses <a href="http://www.relaxng.org/">RELAX NG</a> for validation and CSS for layout. 
+    Integration with Lenya is done with a series of use case steps that are defined
+    in a sitemap inside your publication: <code>usecase-bxeng.xmap</code>. If you understand the purpose
+    of the various use case steps, you will have a good grasp of how to integration is done, and will be
+    able to adjust it to your needs as necessary.</p>
+</section>
+<section>
+<title>The open step</title>
+    <p>The open step is called when you first open BXE from the Lenya menu. It first checks
+        if BXE is installed, and displays a warning page if it is not. It then attempts to check
+        out the page to be edited (to protect it from being edited by other users at the same time),
+        and displays an error page if this fails for some reason. It then loads the BXE start page
+        that contains references to the BXE configuration to be used for this page, such as the
+        location of the RELAX NG schema, CSS files, and more. The BXE start page is a dynamically
+        generated page that is being aggregated from a configuration pipeline (the config step), 
+        a file that contains all the namespaces that may occur in the document to be edited 
+        (<code>content-namespaces.xml</code>), and the skeleton BXE start page (<code>index.xhtml</code>).
+        The pipeline looks like this:
+     </p>
+    <source xml:space="preserve">
+    <![CDATA[
+          <map:match type="step" pattern="open">
+           <!-- Check for BXENG -->
+           <map:act type="resource-exists" src="../../resources/bxeng/bxeLoader.js">
+            <map:act type="reserved-checkout">
+              <map:generate type="serverpages" src="../../content/rc/{exception}.xsp">
+                <map:parameter name="user" value="{user}"/>
+                <map:parameter name="filename" value="{filename}"/>
+                <map:parameter name="date" value="{date}"/>
+                <map:parameter name="message" value="{message}"/>
+              </map:generate>
+              <map:transform src="../../xslt/rc/rco-exception.xsl"/>
+              <map:call resource="style-cms-page"/>
+            </map:act>
+            <map:aggregate element="bxeng">
+              <map:part src="../../resources/misc/bxeng/index.xhtml"/>
+              <map:part src="../../resources/misc/bxeng/content-namespaces.xml"/>
+            </map:aggregate>
+            <map:transform src="../../xslt/bxeng/aggregate.xsl"/>
+            <map:transform src="../../xslt/bxeng/index-xhtml.xsl">
+              <map:parameter name="configfile" value="{request:requestURI}?lenya.usecase=bxeng&amp;lenya.step=config"/>
+              <map:parameter name="context" value="{request:contextPath}"/>
+            </map:transform>
+            <map:serialize type="xhtml"/>
+            </map:act>
+            <map:generate src="../../resources/misc/bxeng/download.xhtml"/>
+            <map:call resource="style-cms-page"/>
+            <map:serialize type="html"/>
+          </map:match>
+    ]]>
+    </source>
+</section>    
+<section>
+<title>The config step</title>
+    <p>The config step generates the BXE config file by transforming a template file (<code>config.xml</code>)
+        and passing in values for the following parameters:
+     </p>
+        <ul>
+        <li>BX_exitdestination: URL of the location BXE should redirect to upon exit</li>
+        <li>BX_validationfile: URL of the RELAX NG schema for the XML to be edited</li>
+        <li>BX_xhtmlfile: URL of the XHTML page to load the XML content into for editing</li>
+        <li>BX_xmlfile: URL of the XML for the page to be edited</li>
+        <li>BX_xslfile: URL of the XSL stylesheet to use for formatting the XML in BXE (BXE 1.1 only)</li>
+        <li>contextmenufile: URL of the file that defines the BXE context menu</li>
+        <li>css: URL of the CSS file used for styling the XML to be edited in BXE</li>
+        <li>defaultlanguage: default language of the publication, used for insert popups</li>
+        </ul>
+      <p>If you want to customize BXE, the config step is your starting point. Make sure to pass
+        in the right URL for these parameters. The default publication uses additional pipelines
+        for these URL to provide more flexibility (such as automatically loading the correct
+        RELAX NG schema based on the resource type of the current page). More information about
+        the format of <code>config.xml</code> is available at the <a href="http://wiki.bitfluxeditor.org/Config.xml">BXE wiki</a>. 
+        The config step pipeline looks as follows in the default publication:</p>
+    <source xml:space="preserve">
+    <![CDATA[
+        <map:match type="step" pattern="config">
+          <map:generate src="../../resources/misc/bxeng/inc/config.xml"/>
+          <map:transform src="../../xslt/bxeng/config-xml.xsl">
+            <map:parameter name="BX_xmlfile" value="{request:requestURI}?lenya.usecase=bxeng&amp;lenya.step=xml"/>
+            <map:parameter name="defaultlanguage" value="{page-envelope:default-language}"/>
+            
+  <!--      Instead of an xsl we use the xhtml file to provide the basic layout
+            <map:parameter name="BX_xslfile" value="{2}.xsl"/>
+  -->
+            <map:parameter name="BX_xhtmlfile" value="{../2}.bxe.html"/>
+            <map:parameter name="BX_validationfile" value="{request:contextPath}/{page-envelope:publication-id}/{page-envelope:area}/{page-envelope:document-type}.rng"/>
+            <map:parameter name="css" value="{request:contextPath}/{page-envelope:publication-id}/{page-envelope:area}/css/{page-envelope:document-type}-bxeng.css"/>
+  <!--       The document is checked in when we exit from bx (in case of save&exit and in case of exit), so we use the usecase
+             for the checkin while we redirect to the document
+  -->
+            <map:parameter name="BX_exitdestination" value="{request:requestURI}?lenya.usecase=checkin&amp;lenya.step=checkin&amp;backup=true"/>
+            <map:parameter name="contextmenufile" value="../../resources/misc/bxeng/contextmenu.xml"/>
+          </map:transform>
+          <map:transform type="cinclude"/>
+          <map:serialize type="xml"/>
+        </map:match>
+    ]]>
+    </source>
+</section>    
+<section>
+<title>The xml step</title>
+    <p>The xml step is responsible for retrieving the XML of the page to be edited, and sending it back to the server
+        for saving (via HTTP PUT). It first checks if the request method is a GET or a PUT, and goes on to either deliver
+        the XML to BXE (for the GET case) or sending the XML to the server (for the PUT case). If the request method
+        is a PUT, it then checks if the page is properly checked out, and invokes a flow script function 
+        (<code>editDocument</code>) to save the page. The <code>editDocument</code> function takes care of checking
+        the page back in, triggering workflow transitions, and finally redirecting to the saved page. This is the
+        xml pipeline from the default publication:</p>
+    <source xml:space="preserve">
+    <![CDATA[
+      <map:match type="step" pattern="xml">      
+        <map:select type="request-method">
+          
+          <map:when test="PUT">
+            <!-- before we save, we must be sure that the document is well checked out
+            -->           
+	        <map:act type="reserved-checkout-test">
+    	      <map:generate type="serverpages" src="../../content/rc/{exception}.xsp">
+        	    <map:parameter name="user" value="{user}"/>
+            	<map:parameter name="filename" value="{filename}"/>
+	            <map:parameter name="date" value="{date}"/>
+    	      </map:generate>
+        	  <map:transform src="../../xslt/rc/rco-exception.xsl"/>
+	          <map:call resource="style-cms-page"/>
+        	</map:act>
+          
+          <map:call function="editDocument">
+            <map:parameter name="sourceUri" value="cocoon:/request2document"/>
+            <map:parameter name="noCheckin" value="true"/>
+          </map:call>
+          </map:when>
+
+          <map:otherwise> <!-- GET -->
+            <map:generate src="content/authoring/{page-envelope:document-path}"/>
+            <map:transform src="../../xslt/bxeng/change-object-path.xsl">
+              <map:parameter name="documentid" value="{page-envelope:document-id}"/>
+            </map:transform>
+            <map:serialize type="xml"/>
+          </map:otherwise>
+          
+        </map:select>
+      </map:match>
+    ]]>
+    </source>
+</section>    
+<section>
+<title>The image-upload-show, link-show and asset-upload-show steps</title>
+    <p>BXE supports the notion of callbacks to allow Lenya to display a list of assets, images or links
+        to be inserted into a page. These three steps generate the content of these popup windows, respectively.
+        The <code>link-show</code> step is the most complex of these since it takes lots of parameters, such
+        as the currently selected language, the position in the sitetree and the list of available languages.
+        These parameters are necessary to recreate the sitetree visualization from the site area for the link
+        insert popup.</p>
+    <source xml:space="preserve">
+    <![CDATA[
+      <map:match pattern="image-upload-show" type="step">
+        <map:call resource="cms-screen">
+           <map:parameter name="serverpage" value="info/assets.xsp"/>
+           <map:parameter name="stylesheet" value="bxeng/image.xsl"/>
+        </map:call>
+      </map:match>
+
+      <map:match pattern="asset-upload-show" type="step">
+        <map:call resource="cms-screen">
+           <map:parameter name="serverpage" value="info/assets.xsp"/>
+           <map:parameter name="stylesheet" value="bxeng/asset.xsl"/>
+        </map:call>
+      </map:match> 
+
+      <map:match pattern="link-show" type="step">
+            <!-- just a dummy xsp since we call the info area directly -->
+           <map:generate type="serverpages" src="../../content/info/assets.xsp"/>
+          <map:transform src="../../xslt/bxeng/link.xsl" label="content">
+            <map:parameter name="infoarea" value="true"/>
+            <map:parameter name="contextprefix" value="{request:contextPath}"/>
+            <map:parameter name="publicationid" value="{page-envelope:publication-id}"/>
+            <map:parameter name="area" value="authoring"/>
+            <map:parameter name="tab" value="en"/>
+            <map:parameter name="chosenlanguage" value="{page-envelope:document-language}"/>
+            <map:parameter name="documentid" value="{page-envelope:document-id}"/>
+            <map:parameter name="documenturl" value="/{page-envelope:document-url}"/>
+            <map:parameter name="documentextension" value="{page-envelope:document-extension}"/>
+            <map:parameter name="defaultlanguage" value="{page-envelope:default-language}"/>
+            <map:parameter name="languages" value="{page-envelope:publication-languages-csv}"/>
+          </map:transform>
+        <map:call resource="style-cms-page"/>
+      </map:match>
+    ]]>
+    </source>
+</section>    
+<section>
+<title>The image-upload and asset-upload steps</title>
+    <p>To enable the upload of new assets to Lenya directly from the BXE <code>insert Image</code> 
+        and <code>insert Asset</code> popup windows, there are two use case steps that use the
+        upload action to process the uploaded file, and then redirect to the respective popup window.</p>
+    <source xml:space="preserve">
+    <![CDATA[
+          <map:match type="step" pattern="asset-upload">
+            <map:act type="upload">
+              <map:redirect-to uri="{request:requestURI}?lenya.usecase=bxeng&amp;lenya.step=asset-upload-show"/>
+            </map:act>
+            <map:call resource="cms-screen">
+              <map:parameter name="serverpage" value="info/assets.xsp"/>
+              <map:parameter name="stylesheet" value="bxeng/asset.xsl"/>
+            </map:call>
+          </map:match>
+
+          <map:match type="step" pattern="image-upload">
+            <map:act type="upload">
+              <map:redirect-to uri="{request:requestURI}?lenya.usecase=bxeng&amp;lenya.step=image-upload-show"/>
+            </map:act>
+	        <map:call resource="cms-screen">
+	           <map:parameter name="serverpage" value="info/assets.xsp"/>
+	           <map:parameter name="stylesheet" value="bxeng/image.xsl"/>
+	        </map:call>
+	       </map:match>
+    ]]>
+    </source>
+</section>    
+<section>
+<title>Further BXE configuration</title>
+    <p>BXE offers a lot of customization options beyond those outlined above. If you plan to make the most
+        of BXE, you should familiarize yourself with the contents of the 
+            <a href="http://wiki.bitfluxeditor.org/Main_Page">BXE wiki</a>.</p>
+</section>    
+
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221908676.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221908676.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221908676.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221908676.bak Fri Nov 16 07:11:58 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>Bitflux Editor</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/23061260-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/23061260-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221908676" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221888248"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910789553" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910762413"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781622729" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.1195221906352.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.1195221906352.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.1195221906352.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.1195221906352.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,238 @@
+<?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: kupu.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>Kupu</title>
+</header> 
+<body> 
+
+<p>Kupu is a browser based WYSIWYG XHTML editor which is developed independently of Lenya by  <a href="http://www.oscom.org/">OSCOM</a>
+ and is available at <a href="http://kupu.oscom.org/"> http://kupu.oscom.org/</a>. Kupu can and actually is being used in other projects as well, that have nothing to do with 
+ Java, XML or the Apache software stack. Lenya is just prepared for the Kupu Editor to be plugged in, and ships with Kupu pre-installed. </p>
+
+<section>
+<title id="head-9b4594a57c32f9b79007a4319d02bc57c1656c90">Kupu as a sample for integrating editors in general</title>
+
+<p>Understanding the Kupu integration in Lenya is helpful to understand how editors are integrated into Lenya at all. This knowledge is
+ important if you are looking into changing the way Kupu is used inside Lenya or if you are thinking about taking any other editor and integrate it in Lenya. </p>
+
+</section>
+<section>
+<title id="head-cb7dd8a2b1dc471e0805416826a330e77b1cce07">What integrating an editor is all about</title>
+
+<p>From the user's perspective using an editor in Lenya works like this: </p>
+<ol>
+<li>
+<p>Navigate to the item that is to be edited </p>
+</li>
+<li>
+<p>Click on a link to start the editing process (mostly from a pull-down menu, but there are other options) </p>
+
+</li>
+<li>
+<p>Edit </p>
+</li>
+<li>
+<p>Save </p>
+</li>
+<li>
+<p>Enjoy the changes </p>
+</li>
+</ol>
+<p>The link to start the editing is nohting but a GET request to an editing usecase. (See: [<a href="http://wiki.apache.org/lenya/CreatePageWalkthrough">CreatePageWalkthrough</a>]
+ for some background on Usecases). The reply to that request is the page that contains the editor with the to be edited file loaded. 
+ As simple as that sounds, there is a number of things Lenya has to go through. </p>
+<p>Between Step 2. and 3. (the user clicking on 'Edit' and the editor showing up) Lenya has to </p>
+
+<ol>
+<li>
+<p>Make sure the editor is installed at all </p>
+</li>
+<li>
+<p>Determine the file to be edited </p>
+</li>
+<li>
+<p>Make sure editing is allowed (i.e. the file is not checked out reserved by someone else) </p>
+</li>
+<li>
+<p>Aggregate the content that is to be edited, the editor part of the page itself and whatever parameter the editor needs and serve it to the browser. </p>
+</li>
+</ol>
+<p>Between Step 3. and 4. (Edit and Save) Lenya has to  </p>
+<ol>
+
+<li>
+<p>Make sure the file is still checked out so it can be edited </p>
+</li>
+<li>
+<p>Extract the edited page content from the HTTP POST </p>
+</li>
+<li>
+<p>Save the edited file </p>
+</li>
+<li>
+<p>Check in the edited file </p>
+</li>
+<li>
+<p>Trigger and workflow events on the document that belong to the "edit" event. </p>
+</li>
+</ol>
+<p>
+<em>Note: Kupu allows the user to Save in between and continue editing. This is achieved by using HTTP POST operations. Thus Lenya needs to be prepared to 
+receive multiple updates of the same page and save it before the user might click on 'Exit and Save' so that Step 5 (Display the changed page) is finally triggered.</em> </p>
+
+</section>
+<section>
+<title id="head-e5a2711688441b7644fbdb11a61307c04fbf2061">The Kupu usecase pipeline in detail</title>
+<section>
+<title id="head-42ce962db03bd610fa943bc40b509ba6985810fd">step="open"</title>
+
+
+<source xml:space="preserve">
+        &lt;map:match pattern="kupu" type="usecase"&gt;
+          &lt;map:match pattern="open" type="step"&gt;
+            &lt;map:match pattern="*/authoring/**.html"&gt;
+
+              &lt;!-- Check for Kupu--&gt;
+              &lt;map:act type="resource-exists" src="resources/kupu/common/kupueditor.js"&gt;
+
+                &lt;map:act type="reserved-checkout"&gt;
+                  &lt;map:generate type="serverpages" src="content/rc/{exception}.xsp"&gt;
+                    &lt;map:parameter name="user" value="{user}"/&gt;
+                    &lt;map:parameter name="filename" value="{filename}"/&gt;
+
+                    &lt;map:parameter name="date" value="{date}"/&gt;
+                    &lt;map:parameter name="message" value="{message}"/&gt;
+                  &lt;/map:generate&gt;
+                  &lt;map:transform src="xslt/rc/rco-exception.xsl"/&gt;
+                  &lt;map:call resource="style-cms-page"/&gt;
+                &lt;/map:act&gt;
+
+                &lt;map:generate src="resources/kupu/apache-lenya/kupumacros.html"/&gt;
+                &lt;map:transform src="resources/kupu/apache-lenya/kupumacros-xhtml.xsl"&gt;
+                  &lt;map:parameter name="contentfile" value="{page-envelope:context-prefix}/{../1}/authoring/{../2}.html?lenya.usecase=kupu&amp;amp;lenya.step=content"/&gt;
+                  &lt;map:parameter name="context" value="{request:contextPath}"/&gt;
+                  &lt;map:parameter name="document-path" value="{page-envelope:document-path}"/&gt;
+
+                  &lt;map:parameter name="root" value="{page-envelope:context-prefix}"/&gt;
+                  &lt;map:parameter name="save-destination" value="{page-envelope:context-prefix}/{../1}/authoring/{../2}.html?lenya.usecase=kupu&amp;amp;lenya.step=save"/&gt;
+                  &lt;map:parameter name="reload-on-save" value="0"/&gt; &lt;!-- 1 means you can see the saving --&gt;
+                  &lt;map:parameter name="use-css" value="1"/&gt;
+                  &lt;map:parameter name="redirect-to" value="{page-envelope:document-name}.html"/&gt;
+
+                &lt;/map:transform&gt;
+                &lt;map:serialize type="html"/&gt;
+              &lt;/map:act&gt;
+              &lt;map:generate src="resources/misc/kupu/download.xhtml"/&gt;
+              &lt;map:call resource="style-cms-page"/&gt;
+            &lt;/map:match&gt;
+
+          &lt;/map:match&gt;
+</source>
+
+</section>
+<section>
+<title id="head-f6ed65665fa1e56a5371d0ab376effe42403dfae">step="content"</title>
+
+
+<source xml:space="preserve">
+          &lt;map:match pattern="content" type="step"&gt;
+            &lt;map:match pattern="*/authoring/**.html"&gt;
+              &lt;map:generate src="pubs/{1}/content/authoring/{page-envelope:document-path}"/&gt;
+
+              &lt;map:transform src="resources/kupu/apache-lenya/kupucontent-xhtml.xsl"&gt;
+                &lt;map:parameter name="css" value="{page-envelope:context-prefix}/{1}/authoring/css/page.css"/&gt;
+              &lt;/map:transform&gt;
+              &lt;map:transform src="xslt/util/strip_namespaces.xsl"/&gt;
+                &lt;map:serialize type="xhtml"/&gt;
+            &lt;/map:match&gt;
+
+          &lt;/map:match&gt;
+</source>
+
+</section>
+<section>
+<title id="head-211e1aede1d0c03aa8411a1d19a43d3f5d18ccc9">step="save"</title>
+
+
+<source xml:space="preserve">
+          &lt;map:match pattern="save" type="step"&gt;
+            &lt;map:select type="request-method"&gt;
+              &lt;map:when test="PUT"&gt;
+
+                &lt;map:act type="reserved-checkout-test"&gt;
+                  &lt;map:generate type="serverpages" src="../../content/rc/{exception}.xsp"&gt;
+                    &lt;map:parameter name="user" value="{user}"/&gt;
+                    &lt;map:parameter name="filename" value="{filename}"/&gt;
+                    &lt;map:parameter name="date" value="{date}"/&gt;
+                    &lt;map:parameter name="message" value="{message}"/&gt;
+
+                  &lt;/map:generate&gt;
+                  &lt;map:transform src="../../xslt/rc/rco-exception.xsl"/&gt;
+                  &lt;map:call resource="style-cms-page"/&gt;
+                &lt;/map:act&gt;
+
+                &lt;map:aggregate element="edit-envelope"&gt;
+                  &lt;map:part element="edited" src="cocoon:/kupu-stream"/&gt;
+
+                  &lt;map:part element="original" src="pubs/{page-envelope:publication-id}/content/authoring/{page-envelope:document-path}"/&gt;
+                &lt;/map:aggregate&gt;
+
+                &lt;map:transform src="resources/kupu/apache-lenya/kupusave-xhtml.xsl"/&gt;
+
+                &lt;map:act type="reserved-checkin"&gt;
+                  &lt;map:generate src="content/rc/{exception}.xsp" type="serverpages"&gt;
+
+                    &lt;map:parameter name="user" value="{user}"/&gt;
+                    &lt;map:parameter name="filename" value="{filename}"/&gt;
+                    &lt;map:parameter name="checkType" value="{checkType}"/&gt;
+                    &lt;map:parameter name="date" value="{date}"/&gt;
+                    &lt;map:parameter name="message" value="{message}"/&gt;
+                  &lt;/map:generate&gt;
+
+                  &lt;map:transform src="xslt/rc/rco-exception.xsl"/&gt;
+                  &lt;map:serialize/&gt;
+                &lt;/map:act&gt;
+
+                &lt;map:transform src="xslt/authoring/edit/addSourceTags.xsl"&gt;
+                  &lt;map:parameter name="source" value="pubs/{page-envelope:publication-id}/content/authoring/{page-envelope:document-path}"/&gt;
+                &lt;/map:transform&gt;
+
+                &lt;map:transform type="write-source"/&gt;
+
+                &lt;!-- Trigger workflow with *edit* action --&gt;
+                &lt;map:act type="workflow"&gt;
+                  &lt;map:parameter name="area" value="{page-envelope:area}"/&gt;
+                  &lt;map:parameter name="document-id" value="{page-envelope:document-id}"/&gt;
+                  &lt;map:parameter name="language" value="{page-envelope:document-language}"/&gt;
+
+                  &lt;map:parameter name="event" value="edit"/&gt;
+                &lt;/map:act&gt;
+
+                &lt;map:serialize type="xml" status-code="204"/&gt;
+              &lt;/map:when&gt;
+            &lt;/map:select&gt;
+          &lt;/map:match&gt;
+
+</source>
+</section>
+</section>
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906352.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906352.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906352.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221906352.bak Fri Nov 16 07:11:58 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>Kupu</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/24406720-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/24406720-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221906352" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221885623"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910787564" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771502"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781617480" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.1195221897004.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.1195221897004.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.1195221897004.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.1195221897004.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,192 @@
+<?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: xopus.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>Xopus</title>
+     
+     
+     
+</header> 
+<body> 
+
+<section>
+<title>About Xopus</title>
+<p>Xopus is a browser based validating in-place wysiwyg XML editor. It uses Javascript, XML Schema and XSLT.
+    At this time, it only works on Internet Explorer. If you need a cross-platform solution, take a look at
+    BXE. Note that Xopus is not open source, but a commerical product by Q42.</p>
+</section>
+    
+<section>
+<title>Demo</title>
+<p>There is an online <a href="http://www.xopus.com/demo/index.html">XOPUS demo</a> available. You need Internet
+    Explorer 5.5 or newer to view the demo.</p>
+</section>
+
+<section>
+<title>Configuration</title>
+<p>Lenya is expecting an <em>@XOPUS:CONTEXT@</em> (e.g. Xopus-2.1.66) directory 
+within your <em>@XOPUS:PATH@</em> (e.g. <em>webapps/ROOT</em>) directory. 
+<em>@XOPUS:CONTEXT@</em> and <em>@XOPUS:PATH@</em> are configured 
+within your <em>local.build.properties</em> (xopus.context resp. xopus.path). 
+The path is relative to <em>usecase.xmap</em>. 
+</p>
+</section>
+
+<section>
+<title>Saving via POST</title>
+<p>To enable saving via POST, one needs to modify <code>$XOPUS/xopusPlugins/datadriver.js</code> as follows</p>
+<source xml:space="preserve">
+<![CDATA[
+    // Save data START
+    alert('Save XML via POST');
+    var result = Application.sendXML(doc, 'POST', name);
+
+    switch (result.status)
+    {
+      case 200:
+        //OK
+        var resultXML = result.responseXML;
+        alert('XML saved');
+        return;
+      case -1:
+        alert('Error while saving ' + name + ':\n\n' + result.responseText);
+        break;
+      default:
+        alert('Server responded not ok while saving ' + name + ':\n\nstatus:' + result.status + '\nmessage: ' + resul
+t.responseText);
+    }
+    // Save data END
+]]>
+</source>
+<p>
+You may change the text of the alerts by something else.
+</p>
+</section>
+
+<section>
+<title>Exit Xopus</title>
+<p>To exit Xopus one needs to modify <code>$XOPUS/xopusPlugins/cmsdriver.js</code> as follows</p>
+<source xml:space="preserve">
+<![CDATA[
+  getExitURL: function(path)
+  {
+    exitURL = path.substring(0, path.indexOf('?'));
+    alert('Exit to: ' + exitURL);
+    return exitURL;
+  },
+]]>
+</source>
+<p>
+You may replace the text of the alert by something else.
+</p>
+</section>
+
+<section>
+<title>Making a page editable with Xopus: Schemas, Views (XSLT) and Menus</title>
+<p>Xopus needs an XML Schema for validation and an XSLT to view the document. The Schemas and XSLTs need to be located at:</p>
+<source xml:space="preserve">
+<![CDATA[
+$PUBLICATION/config/doctypes/schemas/$DOCTYPE.xsd
+$PUBLICATION/lenya/xslt/xopus/$DOCTYPE.xsl
+]]>
+</source>
+<p>
+You might want to use <a href="http://www.thaiopensource.com/relaxng/trang.html">Trang</a> to generate XML Schemas.
+</p>
+<p>
+Editing with Xopus is implemented as a usecase. One can add a menu item as follows:
+</p>
+<source xml:space="preserve">
+<![CDATA[
+<item uc:usecase="xopus" uc:step="open" href="?doctype=$DOCTYPE">Edit&#160;with&#160;Xopus</item>
+]]>
+</source>
+<p>In addition, you may want to study the oscom publication which has an Xopus integration example, 
+    as well as the root xopus.xmap, the xopus.xmap in the oscom publication, and the section in 
+    usecase.xmap pertaining to xopus. This will help you understand how the integration was done
+    (which admittedly is a bit clunky as it predates many Lenya concepts).
+    </p>
+</section>
+<section>
+<title>Things to watch out for</title>
+<section>
+    <title>Check your Internet Explorer cache settings</title>
+<p>Make sure that the page is loaded from scratch everytime you visit it, because
+otherwise you'll always see a cached version. This cached version will be
+saved if you click on 'save' in Xopus.</p>
+</section>
+<section>
+    <title>Check your local.build.properties</title>
+<p>Your variable settings could look like this:</p>
+<source xml:space="preserve">
+<![CDATA[
+  xopus.context=Xopus-2.1.72   root directory for all Xopus files
+  xopus.path=../../ROOT        relative path from usecase.xmap to Xopus root
+                               directory
+]]>
+</source>
+</section>
+    <section>
+    <title>Check your schema files</title>
+<p>I had troubles with schemas including other schema files. You have to insert a
+separate pipeline for this kind of architecture. Unfortunately I couldn't
+figure out if I had to put this matcher in
+'$PUBLICATION/publication-sitemap.xmap' or elsewhere. I ended up using one and
+only one schema file for a specific doctype.</p>
+</section>
+<section>
+    <title>Check your CSS files</title>
+<p>You have to provide a stylesheet for Xopus in
+'$PUBLICATION/lenya/xslt/xopus/$DOCTYPE.xsl'. If you use a *.css file to
+control layout and style of the XML file displayed by Xopus, you'll have to
+insert a pipeline matcher in '$PUBLICATION/publication-sitemap.xmap':</p>
+<source xml:space="preserve">
+<![CDATA[
+  <map:pipeline>
+    <map:match pattern="**/xopus.css">
+      <map:read src="resources/shared/css/xopus.css" mime-type="text/css"/>
+    </map:match>
+  </map:pipeline>
+]]>
+</source>
+</section>
+<section>
+<title>Missing preparexinclude.xsl</title>
+<p>If Xopus complains that it cannot find <code>$XOPUS/xopusPlugins/preparexinclude.xsl</code>, then add the following at that location:</p>
+<source xml:space="preserve">
+<![CDATA[
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet version="1.0"
+                       xmlns:x="http://www.w3.org/2001/XInclude"
+                       xmlns:xlink="http://www.w3.org/1999/xlink"
+                       xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+                       >
+
+  <xsl:template match="@*|node()">
+    <xsl:copy>
+      <xsl:apply-templates select="@*|node()"/>
+    </xsl:copy>
+  </xsl:template>
+</xsl:stylesheet>]]>
+</source>
+</section>
+</section>
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897004.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897004.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897004.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897004.bak Fri Nov 16 07:11:58 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>Xopus</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/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/257bcd50-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221897004" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221884671"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910783856" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910768882"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781624588" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.1195221897550.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.1195221897550.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.1195221897550.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.1195221897550.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,236 @@
+<?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: navigation.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>The Navigation Framework</title>
+  </header> 
+  <body> 
+
+<section>
+  <title>Introduction</title>
+
+  <p>
+    To goal of the navigation framework is to
+  </p>
+  <ul>
+    <li>
+      simplify and standardize the generation of navigation
+      widgets like menubars, tabs, breadcrumb paths.
+    </li>
+  </ul>
+
+  <p>With the approach that is presented here it shall be possible to
+  </p>
+  <ul>
+    <li>
+      use pre-defined XHTML navigation components and present them
+      with a custom CSS,
+    </li>
+    <li>
+      override these components in a publication whereby the logic
+      can be reused, and
+    </li>
+    <li>
+      create and integrate new publication-specific navigation components
+      using the same scheme.
+    </li>
+  </ul>
+</section>
+    
+<section>
+  <title>Architecture</title>
+  
+  <p>
+    The navigation framework consists of the following components:
+  </p>
+    
+  <dl>
+    <dt>
+<code>/lenya/navigation.xmap</code>
+</dt>
+    <dd>The sitemap where the navigation components are loaded.<br/>
+<br/>
+</dd>
+    <dt>
+<code>/lenya/xslt/navigation/*.xsl</code>
+</dt>
+    <dd>The default navigation components that are shipped with Lenya.<br/>
+<br/>
+</dd>
+    <dt>
+<code>/lenya/pubs/lenya/xslt/navigation/*.xsl</code>
+</dt>
+    <dd>Custom navigation components of the publication.<br/>
+<br/>
+</dd>
+  </dl>
+  
+</section>
+
+<section>
+  <title>Using the Navigation Framework</title>  
+  
+  <section>
+<title>Loading a Navigation Component</title>
+  
+    <p>
+      You can load a navigation component from the following URI:
+    </p>
+<source xml:space="preserve"><![CDATA[
+cocoon://navigation/<pub-id>/<component>/<path>.xml
+]]></source>
+
+<p>
+The URI steps are:
+</p>
+<dl>
+  <dt>
+<code>&lt;pub-id&gt;</code>
+</dt>
+  <dd>The publicaton ID.</dd>
+  <dt>
+<code>&lt;component&gt;</code>
+</dt>
+  <dd>The navigation component to load (tabs, menu, etc.).</dd>
+  <dt>
+<code>&lt;path&gt;</code>
+</dt>
+  <dd>The navigation path. It is a concatenation of the <code>href</code>
+    attributes of the sitetree nodes that lead to the current node,
+    e.g. <code>demo/oscom.html</code> for the sitetree
+    fragment
+  </dd>
+</dl>
+<source xml:space="preserve"><![CDATA[
+<site xmlns="http://apache.org/cocoon/lenya/sitetree/1.0">
+  <node href="demo/" label="Demo">
+    <node href="oscom.html" label="OSCOM"/>
+    ...
+  </node>
+  ...
+</site>
+]]></source>
+  
+  </section>
+  
+  <section>
+<title>Aggregating the Navigation Components</title>
+  
+  <p>
+    The basic principle is shown in the following figure:
+  </p>
+  <p>
+  <img alt="" src="lenya-document:6824ed30-8731-11dc-ae46-9e7b5d14892d"/>
+  </p>
+  
+  <p>
+    In the publication sitemap (<code>lenya/pubs/&lt;pub-id&gt;/sitemap.xmap</code>)
+    the navigation components are aggregated. Here you decide which components
+    you want to use:
+  </p>
+<source xml:space="preserve"><![CDATA[
+    <map:pipeline>
+      <map:match pattern="navigation/**.html">
+(1)       <map:aggregate element="page" prefix="page"
+              ns="http://apache.org/cocoon/lenya/cms-page/1.0">
+              
+(2)         <map:part src="cocoon://navigation/
+                {publication-id}/breadcrumb/{../1}.html.xml"/>
+                
+(3)         <map:part src="cocoon://navigation/
+                {publication-id}/tabs/{../1}.html.xml"/>
+                
+(4)         <map:part src="cocoon://navigation/
+               {publication-id}/menu/{../1}.html.xml"/>
+               
+          </map:aggregate>
+          
+(5)       <map:transform src="xslt/page2xhtml.xsl">
+(6)          <map:parameter name="root"
+                 value="{context}/{publication-id}/"/>
+          </map:transform>
+        
+(7)     <map:serialize type="xhtml"/>
+
+      </map:match>
+    </map:pipeline>
+]]></source>
+  
+<ol>
+  <li>
+    The navigation elements are aggregated together with other document parts.
+  </li>
+  <li>
+    Load the breadcrumb XHTML fragment.
+  </li>
+  <li>
+    Load the tabs XHTML fragment.
+  </li>
+  <li>
+    Load the menu XHTML fragment.
+  </li>
+  <li>
+    Create the XHTML page.
+  </li>
+  <li>
+    The stylesheet can use this parameter to generate absolute URLs.
+  </li>
+  <li>
+    Finally, serialize the page as XHTML.
+  </li>
+</ol>
+
+  </section>
+  
+</section>
+  
+<section>
+  <title>Developing Navigation Components</title>
+  
+  <p>
+    The following contracts define the development of navigation components:
+  </p>
+  <ul>
+    <li>A navigation component is an XSLT stylesheet that is located at<br/>
+<br/>
+    <dl>
+      <dt>
+<code>lenya/xslt/navigation/&lt;component&gt;.xsl</code>
+</dt>
+      <dd>for default components and<br/>
+<br/>
+</dd>
+      <dt>
+<code>lenya/pubs/&lt;publication-id&gt;/lenya/xslt/&lt;component&gt;.xsl</code>
+</dt>
+      <dd>for default components.<br/>
+<br/>
+</dd>
+    </dl>
+    </li>
+    <li>
+      The default components produce an XHTML fragment with the
+      top level element <![CDATA[<div class="<component>"/>]]>.
+    </li>
+  </ul>
+
+</section>
+
+  </body> 
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897550.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897550.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897550.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897550.bak Fri Nov 16 07:11:58 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>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/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/26cabb80-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221897550" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221885642"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910799162" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770064"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781625282" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.1195221902947.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.1195221902947.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.1195221902947.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.1195221902947.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,85 @@
+<?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: xhtml-templating.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>XHTML templating</title>
+     
+    <type>Overview document</type> 
+     
+</header> 
+<body> 
+
+<section>
+<title>The XHTML Templating Concept</title> 
+<p>There are various approaches to templating within a Lenya
+publication. The XHTML approach is effective under the following
+conditions:
+</p>
+<ul>
+  <li>Designers want to edit the layout with their conventional tools.</li> 
+<li>The page layout contains large parts of static HTML.</li>
+<li>Pages are typically composed of simple elements.</li>
+</ul>
+
+<p>
+If these conditions are met, it is possible to define the overall
+layout of a page in a XHTML document, using tools like Dreamweaver.
+Special placeholders need to be inserted to indicate where Lenya
+elements should later be substituted. This can be done by inserting
+&lt;div id="navigation" /&gt; as the placeholder for the navigation, for
+instance, or &lt;div id="cmsbody" /&gt; for the body part of a page.
+</p>
+<p>
+If these XHTML documents are finished, they can then be called
+from Lenya, and the placeholders be substituted with CMS content.
+Schematically, this process looks as follows:
+</p>
+<p>1)</p>
+
+<p>XML document (article)    -&gt;</p>
+<p>XML document (navigation) -&gt;  Aggregation to one XML document</p>
+<p>XHTML template            -&gt;</p> 
+
+<p>2)</p>
+
+<p>aggregated XML document   -&gt;  Processing with XSLT</p>
+<p>
+Step 2) identifies the various placeholders ( &lt;div id="navigation" /&gt;
+and &lt;div id="cmsbody" /&gt; in this example) and applies XSL transformations
+to substitute the placeholders with the transformed contents of
+(navigation, article) respectively.
+</p>
+<p>
+What are the advantages of this approach?</p>
+<ul>
+  <li>less XSLT is required, making it easier to delegate design work</li>
+<li>XSLT are easier to understand, as they only affect a small part
+  of a page</li>
+</ul>
+<p>What are the pitfalls of this approach?</p>
+<ul>
+  <li>it may not be appropriate to put the content (here: article) into
+  the XHTML format</li>
+<li>template reuse may be hampered</li>
+</ul>
+</section>
+
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221902947.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221902947.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221902947.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221902947.bak Fri Nov 16 07:11:58 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>XHTML templating</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/280a4060-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/280a4060-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221902947" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221881963"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910799512" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770229"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781618089" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.1195221907351.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.1195221907351.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.1195221907351.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.1195221907351.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,86 @@
+<?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: static-resources.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>Serving Static Resources</title>
+     
+    <type>Overview document</type> 
+     
+</header> 
+<body> 
+
+<section>
+<title>Serving Static Resources</title> 
+<p>Lenya now serves static resources out of the box. Publications can either
+use these predefined mappings, or provide their own. The following MIME types
+are handled:
+</p>
+<ul>
+  <li>CSS</li> 
+<li>Javascript</li>
+<li>Images (GIF, JPEG and PNG)</li>
+<li>PDF</li>
+<li>Shockwave Flash (*.swf)</li>
+</ul>
+
+<p>
+To use the built-in matching, these resources need to be stored in the
+appropriate directories within a publication, and called with the proper
+URLs.
+</p>
+<table>
+<tr>
+<td colspan="1" rowspan="1">MIME Type</td>
+<td colspan="1" rowspan="1">Prefix</td>
+<td colspan="1" rowspan="1">Directory</td>
+</tr>
+<tr>
+<td colspan="1" rowspan="1">CSS</td>
+<td colspan="1" rowspan="1">css/</td>
+<td colspan="1" rowspan="1">resources/css/</td>
+</tr>
+<tr>
+<td colspan="1" rowspan="1">Javascript</td>
+<td colspan="1" rowspan="1">javascript/</td>
+<td colspan="1" rowspan="1">resources/javascript/</td>
+</tr>
+<tr>
+<td colspan="1" rowspan="1">Images</td>
+<td colspan="1" rowspan="1">images/</td>
+<td colspan="1" rowspan="1">resources/images/</td>
+</tr>
+<tr>
+<td colspan="1" rowspan="1">PDF</td>
+<td colspan="1" rowspan="1">pdf/</td>
+<td colspan="1" rowspan="1">resources/pdf/</td>
+</tr>
+<tr>
+<td colspan="1" rowspan="1">Flash</td>
+<td colspan="1" rowspan="1">flash/</td>
+<td colspan="1" rowspan="1">resources/flash/</td>
+</tr>
+</table>
+<p>An image would thus be called with &lt;img src="images/logo.gif" /&gt;
+You dont have to worry about absolute vs relative image paths as long
+as you use URLs that follow this pattern.</p>
+</section>
+
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907351.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907351.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907351.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907351.bak Fri Nov 16 07:11:58 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>Serving static resources</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/2947a260-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/2947a260-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221907351" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221886895"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910788565" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910761861"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781623914" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.1195221899212.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.1195221899212.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.1195221899212.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.1195221899212.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,319 @@
+<?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: lenya-menubar.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>The Lenya Menubar</title>
+     
+     
+     
+</header> 
+<body>
+  
+<section>
+<title>Defining the Menubar</title>
+
+<section>
+<title>The XML Structure</title>
+<p>
+  A menubar declaration contains the definition of several menus.
+  Each menu consists of a set of blocks containing items.
+  The structure of a menu declaration looks as follows:
+</p>
+
+<source xml:space="preserve"><![CDATA[<menu xmlns="http://apache.org/cocoon/lenya/menubar/1.0">
+
+  <menus>
+    
+    <menu label="File" name="File">
+      <block>
+        <item href="...">New Document</item>
+        <item href="...">New Language Version</item>
+        ...
+      </block>
+      ...
+    </menu>
+    
+    ...
+
+  </menus>
+
+</menu>]]></source>
+</section>
+
+<section>
+<title>Showing Blocks and Items Only in Certain Tabs</title>
+
+<p>
+  When you use the same menu declaration for different tabs,
+  it might be wished that a menu item shouldn't appear in all
+  these tabs. For instance, the <em>Edit</em> menu item should
+  be displayed only in the <em>authoring</em> tab menu.
+</p>
+<p>
+  To disable a menu item or block, you add an attribute with
+  the name of the tab (<em>authoring</em>, <em>info</em>)
+  and the value <code>false</code>:
+</p>
+<source xml:space="preserve"><![CDATA[<item info="false">...</item>
+
+<block authoring="false">
+  ...
+</block>
+]]></source>
+
+</section>
+
+<section>
+<title>Specifying Usecases and Workflow Events</title>
+
+<p>
+  When a menu item calls a usecase or triggers a workflow transition,
+  and the corresponding action is not allowed, the <code>href</code>
+  attribute of the item is removed before the menu is rendered to
+  disable the item. For this purpose, the <code><![CDATA[<item>]]></code>
+  element supports the attributes
+</p>
+
+<ul>
+  <li>
+<code>wf:event</code>,</li>
+  <li>
+<code>uc:usecase</code>, and</li>
+  <li>
+<code>uc:step</code>.</li>
+</ul>
+  
+<p>
+  If the attributes are provided, they are translated into the
+  appropriate request parameters:
+</p>
+
+<ul>
+  <li>
+<code>wf:event -&gt; lenya.event</code>
+</li>
+  <li>
+<code>uc:usecase -&gt; lenya.usecase</code>
+</li>
+  <li>
+<code>uc:step -&gt; lenya.step</code>
+</li>
+</ul>
+  
+<p>
+  The attributes are used in the following way:
+</p>
+
+<source xml:space="preserve"><![CDATA[<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">
+
+  ...
+
+  <item wf:event="edit"
+        uc:usecase="edit-forms"
+        uc:step="open" href="?...">Edit with Forms</item>
+  
+  ...
+
+</menu>]]></source>
+
+<p>
+  The resulting request would be
+</p>
+<source xml:space="preserve">?lenya.event=edit&amp;lenya.usecase=edit-forms&amp;lenya.step=open&amp;...</source>
+<p>
+  If a user is not allowed to invoke the event <code>edit</code>
+  or to execute the usecase <code>edit-forms</code>, the menu
+  item will be disabled.
+</p>
+
+</section>
+
+</section>
+  
+<section>
+<title>Applying the Menubar - Meta Stylesheet Approach</title>
+
+<p>
+In this approach, the publication simply builds its XHTML
+page without any additional XML. The Lenya menubar is added using
+a meta stylesheet in the last transformation step.
+You find more information on meta stylesheets on the page
+<a href="ext:wiki/lenya/MetaStylesheets">MetaStylesheets</a>
+in the Cocoon wiki.
+</p>
+
+<section>
+<title>The Big Picture (literally)</title>
+
+<p>
+<img alt="Lenya page processing" src="lenya-document:67c65270-8731-11dc-ae46-9e7b5d14892d"/>
+</p>
+<p>
+In the left column you see the XML flow within the publication sitemaps,
+  the right column shows the flow within the core sitemaps.
+</p>
+
+<section>
+<title>Creating the Menu XHTML</title>
+<ul>
+  <li>The actual menu XML is fetched from the sitemap <code>menus.xmap</code>
+  within the publication directory.</li>
+  <li>The XML is processed using the UsecaseMenuTransformer and the
+  WorkflowMenuTransformer.</li>
+  <li>The stylesheet <code>lenya/xslt/menu/menu2xhtml.xsl</code> transforms
+  the menu XML into XHTML.</li>
+  <li>Finally, this XHTML is transformed into a meta stylesheet by
+  <code>lenya/xslt/menu/menu2xslt.xsl</code>.</li>
+</ul>
+</section>
+
+<section>
+<title>Requesting and Applying the Menubar</title>
+<ul>
+  <li>The XHTML page is generated without any additional XML.</li>
+  <li>Afterwards, the menubar meta stylesheet is requested using
+  a <code>cocoon://lenya-page/...</code> internal request.</li>
+  <li>This request is matched in <code>global-sitemap.xmap</code>.</li>
+  <li>The menubar meta stylesheet is applied to the XHTML page.
+  It inserts the menubar at the top of the HTML body, adds some
+  additional CSS file entries and modifies the HTML title.</li>
+</ul>
+</section>
+
+</section>
+
+<section>
+<title>Configuring the Publication</title>
+
+<section>
+<title>Requesting the lenya-page Meta Stylesheet</title>
+<p>The lenya-page meta stylesheet request looks as follows:</p>
+
+<source xml:space="preserve"><![CDATA[
+<map:generate src="cocoon:/page/..."/>
+<map:transform src="cocoon://lenya-page/{page-envelope:publication-id}/[menu-url]"/>
+<map:serialize type="html"/>
+]]></source>
+
+<ul>
+  <li>The <code>lenya-page</code> part is used to match the request in <code>global-sitemap.xmap</code>.</li>
+  <li>The <code>{page-envelope:publication-id}</code> part is used to evaluate which
+  publication the request came from.</li>
+  <li>The <code>[menu-url]</code> part is used to get the menu from <code>menus.xmap</code>.
+  Here you have to add all information you need to select the appropriate menubar.</li>
+</ul>
+</section>
+
+<section>
+<title>Creating the Menu XML</title>
+<p>Usually, this is done using an XSP page.</p>
+<p>The Lenya menubar namespace is</p>
+<source xml:space="preserve">http://apache.org/cocoon/lenya/menubar/1.0</source>
+</section>
+
+<section>
+<title>Supplying Menus in menus.xmap</title>
+<p>When the lenya-page meta stylesheet is generated in the core,
+the actual menu XML is fetched using a request to the sitemap
+<code>menus.xmap</code> in the publication directory.
+The <code>[menu-url]</code> part from the lenya-page request is
+matched in this sitemap.</p>
+
+<p>
+This simple <code>menus.xmap</code> pipeline uses different
+menus for authoring and live:
+</p>
+
+<source xml:space="preserve"><![CDATA[
+<map:pipeline>
+  
+  <map:match pattern="live/**">
+    <map:generate type="serverpages"
+        src="../../content/menus/live.xsp"/>
+    <map:serialize type="xml"/>
+  </map:match>
+  
+  <map:match pattern="*/**">
+    <map:generate type="serverpages"
+        src="config/menus/generic.xsp"/>
+    <map:serialize type="xml"/>
+  </map:match>
+  
+</map:pipeline>
+]]></source>
+
+<p>You can as well use the document type or the current URL to
+select a menu.</p>
+
+<p>Examples for lenya-page requests:</p>
+
+<p>Using the area:</p>
+<source xml:space="preserve">cocoon://lenya-page/{page-envelope:publication-id}/{page-envelope:area}</source>
+
+<p>Using the document type:</p>
+<source xml:space="preserve">cocoon://lenya-page/{page-envelope:publication-id}/{page-envelope:document-type}</source>
+
+<p>Using the document URL:</p>
+<source xml:space="preserve">cocoon://lenya-page/{page-envelope:publication-id}/{page-envelope:document-url}</source>
+
+</section>
+
+</section>
+
+<section>
+<title>Creating a Customized Menu</title>
+
+<p>
+  It is also possible to get the menu XML before it is transformed
+  to XHTML using a request to the core. For this purpose, the prefix
+  <code>menu-xml</code> is used instead of <code>lenya-page</code>.
+  This way, you can aggregate the menu XML together with other page parts
+  and include it somewhere inside the XML page.
+</p>
+
+<source xml:space="preserve"><![CDATA[<map:aggregate element="lenya" label="aggregation">
+  <map:part src="cocoon:/lenyabody/{1}/{2}.xml"/>
+  <map:part src="cocoon://menu-xml/{page-envelope:publication-id}/{1}.xml"/>
+</map:aggregate>]]></source>
+</section>
+
+</section>
+
+
+<section>
+<title>Applying the Menubar - Classic Approach</title>
+
+<note>This approach is deprecated.</note>
+
+<section>
+<title>XSLT</title>
+<p>
+By editing <code>src/webapp/lenya/xslt/menu/menu.xsl</code> one can change the look and feel of the Lenya menu bar.
+This XSLT template is being included by <code>src/webapp/lenya/xslt/menu/root.xsl</code>.
+</p> 
+</section>
+
+</section>
+
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221899212.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221899212.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221899212.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221899212.bak Fri Nov 16 07:11:58 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>Lenya Menubar</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/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/2a82ba70-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221899212" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221888844"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910797793" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910769068"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781619558" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.1195221895584.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.1195221895584.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.1195221895584.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.1195221895584.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,93 @@
+<?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: pageenvelopemodule.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>The PageEnvelopeModule</title>
+    
+    
+    
+  </header>
+  <body>
+
+<section>
+<title>Overview</title>
+<p>
+The <code>PageEnvelopeModule</code> is an <code>InputModule</code>
+that provides access to the <code>PageEnvelope</code> parameters. For
+documentation on input modules see section <a href="http://cocoon.apache.org/2.1/userdocs/concepts/modules.html">Modules</a>
+of the Cocoon documentation.
+</p>
+</section>
+  
+<section>
+<title>Module Parameters</title>
+<dl>
+  <dt>publication-id</dt>
+  <dd>The current publication ID.</dd>
+  <dt>context-prefix</dt>
+  <dd>The context prefix of the web application, e.g. <code>/lenya</code>.</dd>
+  <dt>area</dt>
+  <dd>The CMS area, <code>authoring</code> or <code>live</code>.</dd>
+  <dt>publication</dt>
+  <dd>The current publication</dd>
+  <dt>document-id</dt>
+  <dd>The document ID, i.e. the path of the document in the sitetree.</dd>
+  <dt>document-name</dt>
+  <dd>The document name, i.e. the very last part of the document ID.</dd>
+  <dt>document-url</dt>
+  <dd>The URL of the document within the area, e.g., <code>/news/index.html</code>
+</dd>
+  <dt>document-path</dt>
+  <dd>The file path where this document is physically located in the
+  file system.</dd>
+  <dt>document-language</dt>
+  <dd>The language of this document.</dd>
+  <dt>document-type</dt>
+  <dd>The document type.</dd>
+</dl>
+</section>
+
+<section>
+<title>Sitemap usage</title>
+<source xml:space="preserve">
+<![CDATA[<map:parameter name="document-id" value="{page-envelope:document-id}"/>]]>
+</source>
+</section>
+
+<section>
+<title>XSP usage</title>
+<source xml:space="preserve">
+<![CDATA[<xsp:page
+       language="java"
+       xmlns:xsp="http://apache.org/xsp"
+       xmlns:input="http://apache.org/cocoon/xsp/input/1.0">
+
+<usecase:url>
+  <input:get-attribute
+      module="page-envelope" as="string" name="document-url"/>
+</usecase:url>
+  
+</xsp:page>       
+]]>
+</source>
+</section>
+
+
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221895584.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221895584.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221895584.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221895584.bak Fri Nov 16 07:11:58 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>PageEnvelopeModule</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/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/2c0b5640-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221895584" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221883209"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910785046" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910769525"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781619391" version="1"/>



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