Project

General

Profile

« Previous | Next » 

Revision 4307

upgrade to MapBuilder 1.5rc2 - includes support for Firefox 3 compatibility (yes, it is also EOLed)

View differences:

wfs_Delete.xsl
1
<?xml version="1.0" encoding="ISO-8859-1"?>
2

  
3

  
4

  
5
<!--
6

  
7
Description: Extract FeatureMembers from a FeatureCollection and build
8

  
9
  into a WFS Insert transaction.
10

  
11
Author:      Cameron Shorter
12

  
13
Licence:     LGPL as specified in http://www.gnu.org/copyleft/lesser.html .
14

  
15

  
16

  
17
$Id$
18

  
19
-->
20

  
21

  
22

  
23
<xsl:stylesheet version="1.0" 
24

  
25
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
26

  
27
    xmlns:wfs="http://www.opengis.net/wfs"
28

  
29
    xmlns:ogc="http://www.opengis.net/ogc"
30

  
31
    xmlns:gml="http://www.opengis.net/gml">
32

  
33

  
34

  
35
  <xsl:output method="xml" omit-xml-declaration="no" encoding="utf-8" indent="yes"/>
36

  
37

  
38

  
39
  <!-- Match root -->
40

  
41
  <xsl:template match="/">
42

  
43
    <wfs:Transaction service="WFS" version="1.0.0">
44

  
45
      <xsl:apply-templates/>
46

  
47
    </wfs:Transaction>
48

  
49
  </xsl:template>
50

  
51

  
52

  
53
  <!-- Match featureMember -->
54

  
55
  <xsl:template match="gml:featureMember/*[@fid]">
56

  
57
    <wfs:Delete typeName="{name()}">
58

  
59
      <ogc:Filter>
60

  
61
        <ogc:FeatureId fid="{./@fid}"/>
62

  
63
      </ogc:Filter>
64

  
65
    </wfs:Delete>
66

  
67
  </xsl:template>
68

  
69

  
70

  
71
  <xsl:template match="text()|@*"/>
72

  
73
</xsl:stylesheet>
74

  
1
<?xml version="1.0"?>
2
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:wfs="http://www.opengis.net/wfs" xmlns:ogc="http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml" version="1.0"><xsl:output method="xml" omit-xml-declaration="yes" encoding="utf-8" indent="yes"/><xsl:template match="/"><wfs:Transaction xmlns:topp="http://www.openplans.org/topp" service="WFS" version="1.0.0"><xsl:apply-templates/></wfs:Transaction></xsl:template><xsl:template match="gml:featureMember/*[@fid]"><wfs:Delete typeName="{name()}"><ogc:Filter><ogc:FeatureId fid="{./@fid}"/></ogc:Filter></wfs:Delete></xsl:template><xsl:template match="text()|@*"/></xsl:stylesheet>

Also available in: Unified diff