OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   RE: [xml-dev] Can't get XML to display through XSLT

[ Lists Home | Date Index | Thread Index ]

This worked fine for me with both Saxon and IE. What are you using to
process it with?

By the way, the best place to ask XSLT questions is on xsl-list


-----Original Message-----
From: Means, Garann R. [mailto:grmeans@DOC1.WA.GOV]
Sent: Tuesday, March 05, 2002 4:08 PM
To: 'xml-dev@lists.xml.org'
Subject: [xml-dev] Can't get XML to display through XSLT


I am trying to transform an XML document with an XSLT, but all that shows up
are the HTML elements, and the for-each loops don't function correctly. When
I try to open the document in Internet Explorer, all I get are a submit
button and a single checkbox. The XML document without the XSLT shows up
fine and is valid to the best of my knowledge. I've tried everything and
searched everywhere I can think of, but can't see what I'm doing wrong.

Here is the XSLT:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
	<xsl:template match="/">
		<xsl:apply-templates />

	<xsl:template match="/main-menu">
		<form name="frmMenuItm" method="POST">
		<xsl:apply-templates />
		<input type="button" value="Edit" />

	<xsl:template match="main-menu/top-level">
		<xsl:for-each select=".">
			<input type="checkbox" value="1"><xsl:attribute
name="name"><xsl:value-of select="title" /></xsl:attribute></input>
			<a href="#"><xsl:value-of select="title" /></a>



And the XML looks something like this:

		<title>Here is a title.</title>
		<other-tag>Something else.</other-tag>
		<title>Another title.</title>
		<other-tag>More nonsense.</other-tag>

Can anyone help?

Garann Rose Means

The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
initiative of OASIS <http://www.oasis-open.org>

The list archives are at http://lists.xml.org/archives/xml-dev/

To subscribe or unsubscribe from this list use the subscription
manager: <http://lists.xml.org/ob/adm.pl>


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS