1
|
<?xml version="1.0" encoding="ISO-8859-1"?>
|
2
|
|
3
|
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:pmb="http://nsuri.notld/poweredByMapbuilder" xmlns:gml="http://www.opengis.net/gml" xmlns:wfs="http://www.opengis.net/wfs" xmlns:topp="http://www.openplans.org/topp" version="1.0">
|
4
|
|
5
|
<!--
|
6
|
Description: Convert a GML FeatureInfoResponse or FeatureCollection into a OL popup text.
|
7
|
Author: Andreas Hocevar
|
8
|
$Id: TipWidgetOL.xsl 3907 2008-03-06 10:27:06Z steven $
|
9
|
-->
|
10
|
|
11
|
<xsl:output method="xml" encoding="utf-8" omit-xml-declaration="yes"/>
|
12
|
|
13
|
<!-- Common params for all widgets -->
|
14
|
<xsl:param name="modelId"/>
|
15
|
<xsl:param name="widgetId"/>
|
16
|
|
17
|
<!-- params for this widget -->
|
18
|
<xsl:param name="fid"/>
|
19
|
|
20
|
<!-- Main html - It matches only non-empty results -->
|
21
|
<xsl:template match="/">
|
22
|
<div class="PopupContainer">
|
23
|
<xsl:apply-templates/>
|
24
|
</div>
|
25
|
</xsl:template>
|
26
|
|
27
|
<!-- featureInfo -->
|
28
|
<xsl:template match="wfs:FeatureCollection/gml:featureMember">
|
29
|
<xsl:if test="*[@fid=$fid]">
|
30
|
<xsl:value-of select="*[@fid=$fid]//pmb:name"/>
|
31
|
</xsl:if>
|
32
|
</xsl:template>
|
33
|
|
34
|
<!-- Remove documentation, text, comments -->
|
35
|
<xsl:template match="comment()|text()|processing-instruction()">
|
36
|
</xsl:template>
|
37
|
</xsl:stylesheet>
|