Community-Credit.com | NonProfitWays.com | SOAPitstop.com   Skin:   
      User: Not logged in 
Home
Newsletter Signup
XSLT Library
Latest XML Blogs
Featured Examples
Presentations
Featured Articles
Book Chapters
Training Courses
Events
NewsGroups
 
Discussions
Examples
Tutorials
Tools
Articles
Resources
Websites
 
Sign In
My Profile
My Articles
My Examples
My Favorites
My Resources
Add a Resource
Logout
 
About Me
My Blog
HeadGeek Articles
Talking Portfolio
Resume
Pictures
World Trip Pics

Reply: query on match attribute

Date Posted:2/3/2009 4:58 AM
Posted by:
c c

Hi Friends,


I am new to xslt. I got stuck at usage of match attribute and how it extracts data.


xml :-


?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="p2.xsl"?>
<source>


<bold>Hello, world.</bold>
<red>I am </red>
<italic>fine.</italic>


</source>


xslt :-


<xsl:stylesheet version = '1.0'
     xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>


<xsl:template match="bold">
     <p>
          <b>
               <xsl:value-of select="."/>
          </b>
     </p>
</xsl:template>


</xsl:stylesheet>


o/p:-


Hello, world.


I am fine.


Question :-


How come I am and fine values of "red" and "italic" elements got printed as the code is only for printing the contents of "bold".


Please help me in this regard....


thanks,


ckry






Fans of "The Office"
Dwight Bobbleheads are here!
  “It's me! I'm the bobblehead! Yes!”



Advertise on XMLPitstop

Advertise on XMLPitstop


EggHead Cafe
Web Servicee development
DotNetSlackers
Printer ink
it outsourcing
online fax service
UK conference call service
chicago web design
Registro de Dominios
Domain Names
Car News
Gucci sunglasses
Video Surveillance
Skype vs. sipcall

4,127 Total Members
11 members(last 30 days)
3 members(last 7 days)
0 members(today)

1,948 Total Discussions
0 Posts(last 30 days)
0 Posts(last 7 days)
0 Posts(today)

47,487 Total Blog Posts
0 Blogs(last 30 days)
0 Blogs(last 7 days)
0 Blogs(today)

8,699 Newsgroup Posts
0 Posts(last 30 days)
0 Posts(last 7 days)
0 Posts(today)

14,138 Total Resources
3 Resources(last 30 days)
0 Resources(last 7 days)
0 Resources(today)


 

David Silverlight's XMLPitstop.com| 2801 Florida Ave #225|Miami, FL 33133|Ph:305-447-1139