manishrathi
09-29-2009, 12:13 AM
<?xml version="1.0">
<?xml-stylesheet type="text/xsl" href="article1.xsl"?>
<article>
<logo href="/rocket/images/logo.gif" />
<headline>Blowing XML Bubbles</headline>
<deck>when will bubble burst ? </deck>
<byline href="http://www.beyondhtml.com/default.asp?/rocket/bio.xml>
Michael Floyd</byline>
<pubDate>March 2000</pubDate>
<aBody>
<para>
<dropCap>A</dropCap>t one time or other, everyone from marketing professors to analyst companies has proposed various models to describe the cycle of high flying technologies. Most picture a seed point followed a phase of tremendous hyping</para>
<para>such a model prompted author to direct , on the <bold>editorial page</bold>of the <bold>June 1996 issue of<italic>Web Techniques</italic></bold>, a coolong period for the Web. </para>
<para>Michael is the publisher of BeyondHTML.com an <italic>Web Techniques</italic>editor at large</para>
</aBody>
<copyright>Copyright Michael Floyd. 1998 - 2000. All Rights Reserved</copyright>
</article>
Following rules are applied to this xml document
<xsl:template match="bold">
<B>
<xsl:apply-templates/>
</B>
</xsl:template>
whats meant by this code ? wherever, "bold" is found in xml document , xsl processor will apply B after it. Does it mean that processor will extract text after the "bold" and apply "B" brfore and after it ? Once "B" is encountered, processor extracts text from tyhere on, but how much text will it extract ? upto</bold> ? when </bold> is encountered, does tyhe processor place</B> before it or after it ?
what does the "apply-templates" do ? How is it different from <xsl:value-of select=""> ? If I place <xsl:value-of select=""> instead of <xsl:apply-templates/> , I will get the same result. What templates are applied when I use <xsl:apply-templates > ? If I dont use, <xsl:apply-templates > in the above example , the will it just <B> be applied after <bold> ?
I have done good enough reading and then I posted the question here. So pls dont point to ant article and pls explain.
thanks
<?xml-stylesheet type="text/xsl" href="article1.xsl"?>
<article>
<logo href="/rocket/images/logo.gif" />
<headline>Blowing XML Bubbles</headline>
<deck>when will bubble burst ? </deck>
<byline href="http://www.beyondhtml.com/default.asp?/rocket/bio.xml>
Michael Floyd</byline>
<pubDate>March 2000</pubDate>
<aBody>
<para>
<dropCap>A</dropCap>t one time or other, everyone from marketing professors to analyst companies has proposed various models to describe the cycle of high flying technologies. Most picture a seed point followed a phase of tremendous hyping</para>
<para>such a model prompted author to direct , on the <bold>editorial page</bold>of the <bold>June 1996 issue of<italic>Web Techniques</italic></bold>, a coolong period for the Web. </para>
<para>Michael is the publisher of BeyondHTML.com an <italic>Web Techniques</italic>editor at large</para>
</aBody>
<copyright>Copyright Michael Floyd. 1998 - 2000. All Rights Reserved</copyright>
</article>
Following rules are applied to this xml document
<xsl:template match="bold">
<B>
<xsl:apply-templates/>
</B>
</xsl:template>
whats meant by this code ? wherever, "bold" is found in xml document , xsl processor will apply B after it. Does it mean that processor will extract text after the "bold" and apply "B" brfore and after it ? Once "B" is encountered, processor extracts text from tyhere on, but how much text will it extract ? upto</bold> ? when </bold> is encountered, does tyhe processor place</B> before it or after it ?
what does the "apply-templates" do ? How is it different from <xsl:value-of select=""> ? If I place <xsl:value-of select=""> instead of <xsl:apply-templates/> , I will get the same result. What templates are applied when I use <xsl:apply-templates > ? If I dont use, <xsl:apply-templates > in the above example , the will it just <B> be applied after <bold> ?
I have done good enough reading and then I posted the question here. So pls dont point to ant article and pls explain.
thanks