Hello all,

I need some help with creating an XSL stylesheet for a SensorML document in which the elements include namespace prefixes.

After I modify the SensorML document to reference my XSL stylesheet and try to view the document in Firefox, I get the following error message:

XML Parsing Error: not well-formed
Location: file:///C:/SensorML/DescribeTaskingResponse.xml
Line Number 2, Column 6:

in which line 2 is the line that references the XSL stylesheet.

Here's what I have in the XSL stylesheet so far:

<?xml version="1.0" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
xsi:schemaLocation="http://www.opengis.net/sps spsDescribeTaskingRequestResponse.xsd"
xmlns="http://www.opengis.net/sps spsDescribeTaskingRequestResponse.xsd"
xmlns:sps="http://www.opengis.net/sps/1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ows="http://www.opengis.net/ows"
xmlns:gml="http://www.opengis.net/gml"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:swe="http://www.opengis.net/swe/1.0" >
<xsl:template match="/">
<xsl:for-each select="sps:DescribeTaskingRequestResponse/sps:taskingDescriptor">
<class>
<record>
<xsl:value-of select="sps:sensorID"/>
</record>
</class>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>

And here's part of the SensorML document I'm working with:

<?xml version="1.0" encoding="UTF-8"?>
<?xml:stylesheet type="text/xsl" href="DescribeTaskingResponse.xsl" ?>
<sps:DescribeTaskingRequestResponse
xsi:schemaLocation="http://www.opengis.net/sps spsDescribeTaskingRequestResponse.xsd"
xmlns="http://www.opengis.net/sps spsDescribeTaskingRequestResponse.xsd"
xmlns:sps="http://www.opengis.net/sps/1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ows="http://www.opengis.net/ows"
xmlns:gml="http://www.opengis.net/gml"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:swe="http://www.opengis.net/swe/1.0" >
<sps:taskingDescriptor>
<sps:sensorID>urn:x-ogc:object:sensor:OGC::ROVER_DRT_1202_SN2015</sps:sensorID>
...