W3C home > Mailing lists > Public > www-html@w3.org > August 2003

Re: Using XML to create a compound element

From: <mmuguira@cox.net>
Date: Fri, 1 Aug 2003 15:43:24 -0400
To: www-html@w3.org
Message-Id: <20030801194354.TTAE26675.lakemtao07.cox.net@smtp.central.cox.net>

Hi Danial,
  Sorry if I was unclear, let me show you the an example similar to the pages I've been playing with, only a lot smaller.

test.html:
<?xml-stylesheet type="text/xml" href="./test.xsl">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd" >
<html xmlns="http://www.w3.org/1999/xhtml">
  <myhead>
    <script language="javascript" src="./someRandomScript.js" />
  </myhead>
  <body>
    <h1>Playing with stylesheets</h1>
  </body>
</html>

test.xsl:
<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
  <xsl:template match="myhead">
      <head>
       <title>Title</title>
       <xsl:value-of select="myhead">
      </head>
  </xsl:template>
</xsl:stylesheet>

And I would like to browser to display an html page with the <myhead> . . . </myhead> transformed by the rules in the stylesheet. I've tried numerous variations on this, and I can't help but feel that I'm missing some small thing.

Thanks
Nicholas Muguira
Received on Friday, 1 August 2003 15:44:01 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 5 February 2014 23:40:10 UTC