CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3

Threaded View

  1. #1
    Join Date
    Feb 2007
    Posts
    23

    [RESOLVED] [Please move to the XML forum] domdocument transformnode

    Please move to the XML forum.

    It's possible avoid that transformNode begins the output string with <?xml version='1.0'?>

    For example:

    XML content:

    Code:
    <?xml version="1.0"?>
    <Lista>
    
    	<Pelicula>
    		<Id>100</Id>
    		<Titulo>12 Monos</Titulo>
    	</Pelicula>
    
    	<Pelicula>
    		<Id>101</Id>
    		<Titulo>La nave de la muerte</Titulo>
    	</Pelicula>
    
    </Lista>
    XSL Content:

    Code:
    <?xml version="1.0"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
    
    <xsl:template match="/">
    
    	<xsl:for-each select="Lista/Pelicula">
    		<xsl:value-of select="format-number(number(Id),'000000')"/>
    		<xsl:value-of select="Titulo"/>
    	</xsl:for-each>
    
    </xsl:template>
    
    </xsl:stylesheet>
    The result of the transformation is:

    <?xml version='1.0'?>00010012 Monos000101La nave de la muerte...

    I expects:

    00010012 Monos000101La nave de la muerte...

    Is this possible?

    Thanks
    Last edited by pupito; May 16th, 2007 at 04:28 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured