Subject: Re: [xsl] reolacing tags From: Manu KY <manu_kry@xxxxxxxxx> Date: Fri, 19 Oct 2001 16:53:30 +0530 |
Hi, try this: <?xml version="1.0"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:template match="/"> <html> <xsl:apply-templates/> </html> </xsl:template> <xsl:template match="OTNSC-B"> <b> <xsl:value-of select="."/> </b> </xsl:template> <xsl:template match="body"> <body><xsl:apply-templates/></body> </xsl:template> <xsl:template match="title"> <title><xsl:apply-templates/></title> </xsl:template> <xsl:template match="text"> <text><xsl:apply-templates/></text> </xsl:template> <xsl:template match="news"> <news><xsl:apply-templates/></news> </xsl:template> </xsl:stylesheet>
hi, the problem is:
wherever this is found <OTNSC-B></OTNSC-B>(in xml file) letters letters letters <OTNSC-B>text text</OTNSC-B> letters letters replace it (in the html output) in the same position with <b></b> letters letters letters <b>text text</b> letters letters
Samples:
XML file: <body> <news> <title>Titulo de la new comnes <OTNSC-B>tenebant</OTNSC-B> inde toro pater.</title> <text>Texto de la new <OTNSC-B>Fracti bello</OTNSC-B> fatisque repulsi ducto</text> </news> <news> <title>asd asdasd asdad <OTNSC-B>fghfg</OTNSC-B> fhfg eyeye df d dfh</title> <text>ewferf erfer erg<OTNSC-B>yuky aedths</OTNSC-B> dfgdf dfgdfg dfgd</text> </news> </body>
XSL file resume:
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
_________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] reolacing tags, Amiceto Lopez | Thread | [xsl] omit-xml-declaration="yes" do, Alex Hunsley |
RE: [xsl] create multiple documents, DPawson | Date | [xsl] Re: omit-xml-declaration="yes, Alex Hunsley |
Month |