Hi to all!
IŽd like to insert a tag after the existing
tag!
My XML document content.xml
<?xml version="1.0"?>
<?xml-stylesheet href="Stylesheet.xsl" type="text/xsl"?> <?cocoon-process type="xslt"?> <page> <titles> <title>example</title> </titles> </page> My xml doc which use the fp tags
content.xml
<?xml version="1.0"?>
<!-- Written by Jeremy Quinn "[EMAIL PROTECTED]" --> <?cocoon-process
type="xsp"?>
<?cocoon-process type="xslt"?> <?xml-stylesheet type="text/xsl"
href="form-html.xsl"?>
<xsp:page
xmlns:fp="http://apache.org/cocoon/XSP/FP/1.0" xmlns:request="http://www.apache.org/1999/XSP/Request" xmlns:util="http://www.apache.org/1999/XSP/Util" xmlns:xsp="http://www.apache.org/1999/XSP/Core" language="java" > <page>
<fp:resource id="content-add"> <fp:resource-file>content.xml</fp:resource-file> <fp:resource-node>titles/title[1]</fp:resource-node> <fp:default-mode>insert-before</fp:default-mode> </fp:resource> <fp:resource
id="content-add-after">
<fp:resource-file>content.xml</fp:resource-file> <fp:resource-node>titles/title[1]</fp:resource-node> <fp:default-mode>insert-after</fp:default-mode> </fp:resource> <fp:write to="content-add"
select=".">
<request:get-parameter name="title"/> </fp:write>
<fp:write
to="content-add-after" select=".">
<request:get-parameter name="title"/>
</fp:write>
</page>
</xsp:page> If I try this, it does nothing!
But if I only insert before, it works!
And if I only use insert after, it replace the tag,
but he should add a tag, shouldnt it?
I hope someone can help me!
Sorry for my englich :-)!!!
Timo
|