I
Ian Vaughan
Any ideas why I am not getting any results back in my HTML via XSLT
from my XML doc. It is not returning any errors just no matches when
it should return a value of DATA for SchemeName ??
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl
utput method="html" />
<xsl:template match="/">
<html>
<head>
<title>Building Control</title>
</head>
<body>
<h3>Building Control</h3>
<table border="0" width="80%" cellpadding="2" cellspacing=
"1" bgcolor="#999999">
<tr bgcolor="#dedede">
<th>Scheme</th>
</tr>
<xsl:for-each select="SchemeName">
<tr bgcolor="#ffffff">
<td><xsl:value-of select="SchemeName" /></td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
----------------------------------------
This is my XML Schema
<?xml version="1.0" encoding="UTF-16" ?>
- <BuildingRecordSet xmlns:rs="urn:schemas-microsoft-com:rowset"
xmlns:z="#RowsetSchema"
xmlns:apd="http://www.govtalk.gov.uk/people/AddressAndPersonalDetails">
<SchemeName>DATA</SchemeName>
<LocalAuthorityCode>DATA</LocalAuthorityCode>
- <BuildingRecord>
<SchemeUniqueRecordIdentifier>2</SchemeUniqueRecordIdentifier>
<CompetentPerson>
<PersonRegistrationNumber>02</PersonRegistrationNumber>
<InstallerRegisteredName>Name</InstallerRegisteredName>
</CompetentPerson>
<WorkPerformed>
<PropertyInformation>
<PropertyLocation>
<PropertyAddress>
<apd:A_5LineAddress>
<apd:Line>Bank</apd:Line>
<apd:Line />
<apd:Line />
<apd:Line></apd:Line>
<apd
ostCode></apd
ostCode>
</apd:A_5LineAddress>
</PropertyAddress>
</PropertyLocation>
</PropertyInformation>
<DateWorkCompleted>20/01/2005</DateWorkCompleted>
<DescriptionOfWorkItem>Shower</DescriptionOfWorkItem>
</WorkPerformed>
</BuildingRecord>
</buildingrecordset>
from my XML doc. It is not returning any errors just no matches when
it should return a value of DATA for SchemeName ??
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl
<xsl:template match="/">
<html>
<head>
<title>Building Control</title>
</head>
<body>
<h3>Building Control</h3>
<table border="0" width="80%" cellpadding="2" cellspacing=
"1" bgcolor="#999999">
<tr bgcolor="#dedede">
<th>Scheme</th>
</tr>
<xsl:for-each select="SchemeName">
<tr bgcolor="#ffffff">
<td><xsl:value-of select="SchemeName" /></td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
----------------------------------------
This is my XML Schema
<?xml version="1.0" encoding="UTF-16" ?>
- <BuildingRecordSet xmlns:rs="urn:schemas-microsoft-com:rowset"
xmlns:z="#RowsetSchema"
xmlns:apd="http://www.govtalk.gov.uk/people/AddressAndPersonalDetails">
<SchemeName>DATA</SchemeName>
<LocalAuthorityCode>DATA</LocalAuthorityCode>
- <BuildingRecord>
<SchemeUniqueRecordIdentifier>2</SchemeUniqueRecordIdentifier>
<CompetentPerson>
<PersonRegistrationNumber>02</PersonRegistrationNumber>
<InstallerRegisteredName>Name</InstallerRegisteredName>
</CompetentPerson>
<WorkPerformed>
<PropertyInformation>
<PropertyLocation>
<PropertyAddress>
<apd:A_5LineAddress>
<apd:Line>Bank</apd:Line>
<apd:Line />
<apd:Line />
<apd:Line></apd:Line>
<apd
</apd:A_5LineAddress>
</PropertyAddress>
</PropertyLocation>
</PropertyInformation>
<DateWorkCompleted>20/01/2005</DateWorkCompleted>
<DescriptionOfWorkItem>Shower</DescriptionOfWorkItem>
</WorkPerformed>
</BuildingRecord>
</buildingrecordset>