Project

General

Profile

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 service="WFS" version="1.0.0"><xsl:apply-templates/></wfs:Transaction></xsl:template><xsl:template match="gml:featureMember/*[@fid]"><wfs:Update typeName="{name()}"><ogc:Filter><ogc:FeatureId fid="{./@fid}"/></ogc:Filter><xsl:for-each select="./*"><wfs:Property><wfs:Name><xsl:value-of select="name()"/></wfs:Name><wfs:Value><xsl:if test="./*"><xsl:copy-of select="./*"/></xsl:if><xsl:if test="not(./*)"><xsl:value-of select="."/></xsl:if></wfs:Value></wfs:Property></xsl:for-each></wfs:Update></xsl:template><xsl:template match="text()|@*"/></xsl:stylesheet>
(12-12/18)