• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

xsl templates

 
Ranch Hand
Posts: 386
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is an xml file, that is to be transformed to html document


This is xsl style sheet which transforms xml file into html



Is it must to use <xsl:template match="/"> ? Can I just avoid root template and create xsl by putting "/" as root before article in value-of tag as below ?[html]<?xml version="1.0"?>

Or do I need to have root template in the stylesheet ? How can we create <xsl:apply-templates /> outside root template ? For example, I have a paragraph in xml file which contains some bold words. Now to create these words bold in html doc , I can use following code

This code is used outside root template, why is it allowed outside root template ?

Please explain in detail as reading from book did not help
 
them good ole boys were drinking whiskey and rye singin' this'll be the day that I die. Drink tiny ad.
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic