You are viewing a plain text version of this content. The canonical link for it is here.
Posted to docs@cocoon.apache.org by do...@cocoon.apache.org on 2004/06/23 13:00:45 UTC

[Cocoon Wiki] Updated: Saxon

   Date: 2004-06-23T04:00:45
   Editor: DavidCrossley <cr...@apache.org>
   Wiki: Cocoon Wiki
   Page: Saxon
   URL: http://wiki.apache.org/cocoon/Saxon

   added test text to the last line only

Change Log:

------------------------------------------------------------------------------
@@ -2,50 +2,50 @@
 Add saxon6.5.2.jar to lib/local/
 
 Edit src/webapp/WEB-INF/cocoon.xconf and declare the component for Saxon after the other xslt-processor components ...
-{{{
-<component logger="core.xslt-processor"
-    role="org.apache.excalibur.xml.xslt.XSLTProcessor/saxon"
-    class="org.apache.excalibur.xml.xslt.XSLTProcessorImpl">
-  <parameter name="use-store" value="true"/>
-  <parameter name="incremental-processing" value="false"/>
-  <parameter name="transformer-factory" value="com.icl.saxon.TransformerFactoryImpl"/>
-</component>
+{{{
+<component logger="core.xslt-processor"
+    role="org.apache.excalibur.xml.xslt.XSLTProcessor/saxon"
+    class="org.apache.excalibur.xml.xslt.XSLTProcessorImpl">
+  <parameter name="use-store" value="true"/>
+  <parameter name="incremental-processing" value="false"/>
+  <parameter name="transformer-factory" value="com.icl.saxon.TransformerFactoryImpl"/>
+</component>
 }}}
 
 Edit src/webapp/samples/hello-world/sitemap.xmap to add the "xslt-saxon" transformer ...
-{{{
-<map:components>
-  <map:transformers default="xslt">
-    <map:transformer name="xslt-saxon" pool-grow="2" pool-max="32" pool-min="8"
-        src="org.apache.cocoon.transformation.TraxTransformer">
-      <use-request-parameters>false</use-request-parameters>
-      <use-browser-capabilities-db>false</use-browser-capabilities-db>
-      <xslt-processor-role>saxon</xslt-processor-role>
-    </map:transformer>
-  </map:transformers>
-</map:components>
+{{{
+<map:components>
+  <map:transformers default="xslt">
+    <map:transformer name="xslt-saxon" pool-grow="2" pool-max="32" pool-min="8"
+        src="org.apache.cocoon.transformation.TraxTransformer">
+      <use-request-parameters>false</use-request-parameters>
+      <use-browser-capabilities-db>false</use-browser-capabilities-db>
+      <xslt-processor-role>saxon</xslt-processor-role>
+    </map:transformer>
+  </map:transformers>
+</map:components>
 }}}
 
 Add a sitemap match to use the xslt-saxon transformer ...
-{{{
-<map:match pattern="hello.html">
-  <map:generate src="content/hello.xml"/>
-  <map:transform type="xslt-saxon" src="style/xsl/page2html.xsl"/>
-  <map:serialize type="html"/>
-</map:match>
+{{{
+<map:match pattern="hello.html">
+  <map:generate src="content/hello.xml"/>
+  <map:transform type="xslt-saxon" src="style/xsl/page2html.xsl"/>
+  <map:serialize type="html"/>
+</map:match>
 }}}
 
 Raise the log level to build.webapp.loglevel=DEGUG and look in core.log to see Saxon being used.
 
 ----
 == Saxon7.* and Cocoon-2.1.5 ==
-{{{
-... to be continued ...
+{{{
+... to be continued ...
 }}}
 
 There is a problem with XSP in combination with Saxon7. When the Saxon libraries are in your classpath, the root element of a page generated by XSP gets two extra namespace attributes:
-{{{
-xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:xsp="http://apache.org/xsp"
+{{{
+xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:xsp="http://apache.org/xsp"
 }}}
 This is only noticeable if the XSP generator is immediately followed by a serializer. In this case, Internet Explorer will complain: ''The namespace prefix is not allowed to start with the reserved string "xml".''
 Firefox won't mind these namespace prefixes.
@@ -60,4 +60,4 @@
  1. Discussion: [http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=102248410901124 Re: Saxon and Cocoon]
  1. Discussion: [http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=103114330121800 Re: default xsl transformer?]
  1. Discussion: [http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=104403403124898 Re: BUG: EmptyStackException] - Timothy Larson describes how he configured Saxon
- 1. Discussion: [http://marc.theaimsgroup.com/?t=108009658000004 Re: Using Saxon 7.9 with Cocoon?] (note Vadim's comment about needing CVS version of excalibur-xmlutils)
+ 1. Discussion: [http://marc.theaimsgroup.com/?t=108009658000004 Re: Using Saxon 7.9 with Cocoon?] (note Vadim's comment about needing CVS version of excalibur-xmlutils) added test text

Re: Wiki conversion status

Posted by David Crossley <cr...@apache.org>.
Bertrand Delacretaz wrote:
> David Crossley a écrit :
> 
> > I tried doing some edits today and noticed that the diff
> > emails are very strange. I only changed one line, yet the
> > diff shows that many lines were "changed". I did not have
> > the box selected to "Remove trailing whitespace".
> 
> I've seen this before, seems like it happens on the first edit after 
> importing from the old wiki - the line endings are not the same after 
> you edit the page using the wiki, hence the many diffs.
> 
> IIRC all is ok from the second edit done on the wiki.

Thanks, IDNRC ... i did not remember correctly. This had
arisen once before. Just did a test and it is so.

--David



Re: Wiki conversion status

Posted by Bertrand Delacretaz <bd...@apache.org>.
Le 23 juin 04, à 16:18, Upayavira a écrit :

> ...If someone can tell me what needs to be done (e.g. a run of 
> dos2unix on Minotaur) I can add it to my conversion script. However, 
> as the files now go straight from cocoondev.org (Unix) to 
> wiki.apache.org (Minotaur on Unix), without passing through Charya (my 
> PC, Win2k), I can't see that line endings would be wrong anyway. 
> Hmm...

Line endings was just a wild guess, "something" seems to make it 
different. But it's not such a big deal IMHO, if it's ok after the 
second editi I wouldn't mind.

-Bertrand


Re: Wiki conversion status

Posted by Upayavira <uv...@upaya.co.uk>.
Bertrand Delacretaz wrote:

> Le 23 juin 04, à 15:33, David Crossley a écrit :
>
>> I tried doing some edits today and noticed that the diff
>> emails are very strange. I only changed one line, yet the
>> diff shows that many lines were "changed". I did not have
>> the box selected to "Remove trailing whitespace".
>
>
> I've seen this before, seems like it happens on the first edit after 
> importing from the old wiki - the line endings are not the same after 
> you edit the page using the wiki, hence the many diffs.
>
> IIRC all is ok from the second edit done on the wiki.

If someone can tell me what needs to be done (e.g. a run of dos2unix on 
Minotaur) I can add it to my conversion script. However, as the files 
now go straight from cocoondev.org (Unix) to wiki.apache.org (Minotaur 
on Unix), without passing through Charya (my PC, Win2k), I can't see 
that line endings would be wrong anyway. Hmm.

>
> --Bertrand
>
>



Re: Wiki conversion status

Posted by Bertrand Delacretaz <bd...@apache.org>.
Le 23 juin 04, à 15:33, David Crossley a écrit :

> I tried doing some edits today and noticed that the diff
> emails are very strange. I only changed one line, yet the
> diff shows that many lines were "changed". I did not have
> the box selected to "Remove trailing whitespace".

I've seen this before, seems like it happens on the first edit after 
importing from the old wiki - the line endings are not the same after 
you edit the page using the wiki, hence the many diffs.

IIRC all is ok from the second edit done on the wiki.

--Bertrand


Re: Wiki conversion status

Posted by David Crossley <cr...@apache.org>.
Thanks to Upayavira for continuing the test conversions
of the Cocoon Wiki.

I tried doing some edits today and noticed that the diff
emails are very strange. I only changed one line, yet the
diff shows that many lines were "changed". I did not have
the box selected to "Remove trailing whitespace".

--David

docs<AT>cocoon.apache.org wrote:
>    Date: 2004-06-23T04:00:45
>    Editor: DavidCrossley
>    Wiki: Cocoon Wiki
>    Page: Saxon
>    URL: http://wiki.apache.org/cocoon/Saxon
> 
>    added test text to the last line only
> 
> Change Log:
> 
> ------------------------------------------------------------------------------
> @@ -2,50 +2,50 @@
>  Add saxon6.5.2.jar to lib/local/
>  
>  Edit src/webapp/WEB-INF/cocoon.xconf and declare the component for Saxon after the other xslt-processor components ...
> -{{{
> -<component logger="core.xslt-processor"
> -    role="org.apache.excalibur.xml.xslt.XSLTProcessor/saxon"
> -    class="org.apache.excalibur.xml.xslt.XSLTProcessorImpl">
> -  <parameter name="use-store" value="true"/>
> -  <parameter name="incremental-processing" value="false"/>
> -  <parameter name="transformer-factory" value="com.icl.saxon.TransformerFactoryImpl"/>
> -</component>
> +{{{
> +<component logger="core.xslt-processor"
> +    role="org.apache.excalibur.xml.xslt.XSLTProcessor/saxon"
> +    class="org.apache.excalibur.xml.xslt.XSLTProcessorImpl">
> +  <parameter name="use-store" value="true"/>
> +  <parameter name="incremental-processing" value="false"/>
> +  <parameter name="transformer-factory" value="com.icl.saxon.TransformerFactoryImpl"/>
> +</component>
>  }}}
>  
>  Edit src/webapp/samples/hello-world/sitemap.xmap to add the "xslt-saxon" transformer ...
> -{{{
> -<map:components>
> -  <map:transformers default="xslt">
> -    <map:transformer name="xslt-saxon" pool-grow="2" pool-max="32" pool-min="8"
> -        src="org.apache.cocoon.transformation.TraxTransformer">
> -      <use-request-parameters>false</use-request-parameters>
> -      <use-browser-capabilities-db>false</use-browser-capabilities-db>
> -      <xslt-processor-role>saxon</xslt-processor-role>
> -    </map:transformer>
> -  </map:transformers>
> -</map:components>
> +{{{
> +<map:components>
> +  <map:transformers default="xslt">
> +    <map:transformer name="xslt-saxon" pool-grow="2" pool-max="32" pool-min="8"
> +        src="org.apache.cocoon.transformation.TraxTransformer">
> +      <use-request-parameters>false</use-request-parameters>
> +      <use-browser-capabilities-db>false</use-browser-capabilities-db>
> +      <xslt-processor-role>saxon</xslt-processor-role>
> +    </map:transformer>
> +  </map:transformers>
> +</map:components>
>  }}}
>  
>  Add a sitemap match to use the xslt-saxon transformer ...
> -{{{
> -<map:match pattern="hello.html">
> -  <map:generate src="content/hello.xml"/>
> -  <map:transform type="xslt-saxon" src="style/xsl/page2html.xsl"/>
> -  <map:serialize type="html"/>
> -</map:match>
> +{{{
> +<map:match pattern="hello.html">
> +  <map:generate src="content/hello.xml"/>
> +  <map:transform type="xslt-saxon" src="style/xsl/page2html.xsl"/>
> +  <map:serialize type="html"/>
> +</map:match>
>  }}}
>  
>  Raise the log level to build.webapp.loglevel=DEGUG and look in core.log to see Saxon being used.
>  
>  ----
>  == Saxon7.* and Cocoon-2.1.5 ==
> -{{{
> -... to be continued ...
> +{{{
> +... to be continued ...
>  }}}
>  
>  There is a problem with XSP in combination with Saxon7. When the Saxon libraries are in your classpath, the root element of a page generated by XSP gets two extra namespace attributes:
> -{{{
> -xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:xsp="http://apache.org/xsp"
> +{{{
> +xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:xsp="http://apache.org/xsp"
>  }}}
>  This is only noticeable if the XSP generator is immediately followed by a serializer. In this case, Internet Explorer will complain: ''The namespace prefix is not allowed to start with the reserved string "xml".''
>  Firefox won't mind these namespace prefixes.
> @@ -60,4 +60,4 @@
>   1. Discussion: [http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=102248410901124 Re: Saxon and Cocoon]
>   1. Discussion: [http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=103114330121800 Re: default xsl transformer?]
>   1. Discussion: [http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=104403403124898 Re: BUG: EmptyStackException] - Timothy Larson describes how he configured Saxon
> - 1. Discussion: [http://marc.theaimsgroup.com/?t=108009658000004 Re: Using Saxon 7.9 with Cocoon?] (note Vadim's comment about needing CVS version of excalibur-xmlutils)
> + 1. Discussion: [http://marc.theaimsgroup.com/?t=108009658000004 Re: Using Saxon 7.9 with Cocoon?] (note Vadim's comment about needing CVS version of excalibur-xmlutils) added test text