You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by bosspring 2 <bo...@hotmail.com> on 2003/06/11 18:26:25 UTC

I want to delete a node in XML file.

Hi all !!!

I´m trying to delete a simple node in a XML file, but... how???

Perhaps, I cant to use Source Writing Transformer and replace the node by 
nothing, but....


<usuario login="bosspring" password="6p0JBa2a">
  <nombre>Miguel Ángel</nombre>
  <mail>bosspring@hotmail.com</mail>
  <webmaster>
     <web xmlns:xlink="http://www.w3.org/1999/xlink" 
xlink:href="XML/interpretes.xml#xpointer(//web[@url='http://usuarios.lycos.es/bosspring'])" 
/>
  </webmaster>
</usuario>

I want to delete <web> because the webmaster modifies the content of his 
web, but I don't know.

Thank you.

_________________________________________________________________
Charla con tus amigos en línea mediante MSN Messenger:  
http://messenger.microsoft.com/es


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


Re: I want to delete a node in XML file.

Posted by Joerg Heinicke <jo...@gmx.de>.
You can use XSLT and a identity transformation 
http://www.w3.org/TR/xslt#copying adding a special template handling <web/>:

<xsl:template match="web"/>

Joerg

bosspring 2 wrote:
> Hi all !!!
> 
> I´m trying to delete a simple node in a XML file, but... how???
> 
> Perhaps, I cant to use Source Writing Transformer and replace the node 
> by nothing, but....
> 
> 
> <usuario login="bosspring" password="6p0JBa2a">
>  <nombre>Miguel Ángel</nombre>
>  <mail>bosspring@hotmail.com</mail>
>  <webmaster>
>     <web xmlns:xlink="http://www.w3.org/1999/xlink" 
> xlink:href="XML/interpretes.xml#xpointer(//web[@url='http://usuarios.lycos.es/bosspring'])" 
> />
>  </webmaster>
> </usuario>
> 
> I want to delete <web> because the webmaster modifies the content of his 
> web, but I don't know.
> 
> Thank you.


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