Community
Participate
Working Groups
Build Identifier: 20100218-1602 when i use the xsl file to generate html code using a xml the metadata end tag is not inserted. Reproducible: Always
This would require far more detail than is here now, at minimum an example XML and XSL file showing this behavior. Please reopen when you can attach them.
I`ve got an XML file (books.xml) with the following structure : <?xml version="1.0" encoding="UTF-8"?> <book> <title>Title</title> <author>Author</author> </book> And the I`m creating a XSL (parseBooks.xsl) file to parse the first one : <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="book"> <html> <head> <title></title> </head> <body> <xsl:value-of select="title"></xsl:value-of> <xsl:value-of select="author"></xsl:value-of> </body> </html> </xsl:template> </xsl:stylesheet> On the XSL file I right-click go to Run-As -> XSL Transformation. After this I`ll select the books.xml input file and it creates a new file called books.out.xml and that one has an error called : The element type "META" must be terminated by the matching end-tag "</META>". books.out.xml /WebApp/WebContent line 5 XML Problem So that`s why I wrote to you.
(In reply to comment #2) > I`ve got an XML file (books.xml) with the following structure : > > <?xml version="1.0" encoding="UTF-8"?> > > <book> > <title>Title</title> > <author>Author</author> > </book> > > And the I`m creating a XSL (parseBooks.xsl) file to parse the first one : > > <?xml version="1.0" encoding="UTF-8"?> > <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> > > <xsl:template match="book"> > <html> > <head> > <title></title> > </head> > > <body> > <xsl:value-of select="title"></xsl:value-of> > <xsl:value-of select="author"></xsl:value-of> > </body> > </html> > </xsl:template> > </xsl:stylesheet> > > On the XSL file I right-click go to Run-As -> XSL Transformation. After this > I`ll select the books.xml input file and it creates a new file called > books.out.xml and that one has an error called : > > The element type "META" must be terminated by the matching end-tag "</META>". > books.out.xml /WebApp/WebContent line 5 XML Problem If you ouput your XSL file as HTML, the META tag doesn't have to have a corresponding out. Change you output from book.out.xml to book.out.html and it should open it in the correct editor. Also, you can make sure that it outputs valid HTML by using the appropriate output method in XSL. <xsl:output method="html"/> See XSLT FAQ for more info: http://www.dpawson.co.uk/xsl/sect2/sect21.html > > So that`s why I wrote to you.
Dan, does Davids explanation help, or are you still having a problem? If so, please explain -- otherwise, I'l like to close this bug, or at least turn it into an enhancement request for automatically setting the extension for the output file based on the output method of the transformation or stylesheet.
The explanation hepled me a lot. Thank you very much ! Have a great day !
Resolving as Worksforme as it's not an issue. In general we need to do some enhancments with the launching framework.