cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Geoff Howard <coc...@leverageweb.com>
Subject Re: Writing to filesystem
Date Mon, 16 Jun 2003 12:46:03 GMT
It is complaining about the whitespace nodes between source:frament and 
title.
You'll get this anytime you overwrite a whole document.  To fix, just do 
something
like:

...
   <source:fragment><title>SourceWritingTransformer Test Result 
1</title></source:fragment>
...


At 08:39 AM 6/16/2003, you wrote:
>As quoted from Upayavira <uv@upaya.co.uk>:
> > > Hi,
> > >
> > > What is the best way to write the output of a Transformer (in a
> > > pipeline) into a file (e.g. /resources/bla.xml) on the filesystem?
> >
> > Check out the SourceWritingTransformer.
>
>I am checking it out. thanks. I'm getting an error though:
>
>failedThere was a problem manipulating your document: 
>org.w3c.dom.DOMException: HIERARCHY_REQUEST_ERR: An attempt was made to 
>insert a node where it is not permitted. writenonefile:/resources/result.xml
>
>
>My xml source (called test.xml):
><?xml version="1.0" encoding="UTF-8"?>
><page>
><source:write xmlns:source="http://apache.org/cocoon/source/1.0">
>   <source:source>context://resources/result.xml</source:source>
>   <source:fragment>
>     <title>SourceWritingTransformer Test Result 1</title>
>   </source:fragment>
></source:write>
></page>


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Mime
View raw message