Dear joni santoso,
Please find the XSL File. <?xml version="1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="/"> <xsl:apply-templates/> </xsl:template> <xsl:template match="source"> <html> <xsl:apply-templates/> </html> </xsl:template> <xsl:template match="title"> <title><xsl:value-of select="."/></title> </xsl:template> <xsl:template match="content"> <p><xsl:value-of select="."/></p> </xsl:template> <xsl:template match="heading"> <xsl:element name="[EMAIL PROTECTED]"><xsl:value-of select="."/></xsl:element> </xsl:template> </xsl:stylesheet> Regards, H. Balakrishnan --- joni santoso <[EMAIL PROTECTED]> wrote: > hi, > > i have a question about xslt. could anyone help me? > i want > to display > the child elements of contents like this : > > <!-- > Hi this ... <b>first</b>... > <hr size="1"> > Hi this ... <i>2nd</i>..... > <hr size="2"> > .... > --> > > thx > > my xml: > > <!-- > <?xml version="1.0"?> > <source> > <title>the title</title> > <heading size="2">heading</heading> > <contents> > <content> > Hi this is the <bold>first</bold> > paragraph. > </content> > <line size="1"/> > <content> > Hi this is the <italic>2nd</italic> > paragraph. > <newline/> > Still in <italic>second</italic> > paragraph. > </content> > <line size="2"/> > <content> > Hi this is the <italic>III</italic> > paragraph. > <newline/> > <table> > <row> > <col>name</col> > <col>sex</col> > </row> > <row> > <col>john</col> > <col>male</col> > </row> > </table> > </content> > </contents> > </source> > --> > > and xsl : > > <!-- > <?xml version="1.0"?> > > <xsl:stylesheet version="1.0" > > xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> > > <xsl:template match="/"> > <xsl:apply-templates/> > </xsl:template> > > > <xsl:template match="source"> > <html> > <xsl:apply-templates/> > </html> > </xsl:template> > > <xsl:template match="title"> > <title><xsl:value-of select="."/></title> > </xsl:template> > > <xsl:template match="heading"> > <xsl:element name="[EMAIL PROTECTED]"><xsl:value-of > > select="."/></xsl:element> > </xsl:template> > > <xsl:template match="contents"> > <body> > ? > </body> > </xsl:template> > > </xsl:stylesheet> > --> > =========================================================================================== > Dapatkan Telepon SMS untuk rumah dan kantor hanya di > PlasaCom melalui http://toko.plasa.com > 50% Lebih Murah untuk Domain dan Hosting di > http://idc.plasa.com khusus di bulan Februari ! > =========================================================================================== > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > __________________________________________________ Do you Yahoo!? Yahoo! Tax Center - forms, calculators, tips, more http://taxes.yahoo.com/ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]