[Qgis-developer] WFS Post Request in QGIS server 2.14

20 100 d20100x at gmail.com
Wed Aug 17 21:07:16 PDT 2016


Hi,

I get exactly the same result as Yves. I can't get the POST request to work
with QGIS server 2.14.

Therefore replicating this example with OpenLayers and QGIS server doesn't
seem to be possible.
http://dev.openlayers.org/examples/wfs-spatial-filter.html

v.

------------------------------------------------------------
--------------------------------------------------------------------------
[Qgis-developer] WFS Post Request in QGIS server 2.14*Yves Jacolin* yjacolin
at free.fr
<qgis-developer%40lists.osgeo.org?Subject=Re%3A%20%5BQgis-developer%5D%20WFS%20Post%20Request%20in%20QGIS%20server%202.14&In-Reply-To=%3C2639912.EVDDFNQczy%40tatras%3E>
*Thu Apr 14 04:09:43 PDT 2016*

   - Previous message (by thread): [Qgis-developer] GRASS plugin and
   environmental variables
   <http://lists.osgeo.org/pipermail/qgis-developer/2016-April/042365.html>
   - Next message (by thread): [Qgis-developer] Plugin [976] QAD approval
   notification.
   <http://lists.osgeo.org/pipermail/qgis-developer/2016-April/042358.html>
   - *Messages sorted by:* [ date ]
   <http://lists.osgeo.org/pipermail/qgis-developer/2016-April/date.html#42359>
    [ thread ]
   <http://lists.osgeo.org/pipermail/qgis-developer/2016-April/thread.html#42359>
    [ subject ]
   <http://lists.osgeo.org/pipermail/qgis-developer/2016-April/subject.html#42359>
    [ author ]
   <http://lists.osgeo.org/pipermail/qgis-developer/2016-April/author.html#42359>

------------------------------

Hello,

I try to run a WFS POST request with QGIS server 2.14 without success. I can
get the answer from the similar GET request but not with the POST method.

Anyone tried with success such request? Any working example even if I have no
access to the data, just to llok at the form of the request structure?

Here is my request with curl:

curl --data '<wfs:GetFeature xmlns:wfs="http://www.opengis.net/wfs"
service="WFS" version="1.0.0" maxFeatures="200"
xsi:schemaLocation="http://www.opengis.net/wfs
http://schemas.opengis.net/wfs/1.0.0/wfs.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><wfs:Query
typeName="borders" srsName="EPSG:2154"><ogc:Filter
xmlns:ogc="http://www.opengis.net/ogc"><ogc:PropertyIsLike matchCase="false"
wildCard="*" singleChar="."
escapeChar="!"><ogc:PropertyName>FIPS</ogc:PropertyName><ogc:Literal>FR</ogc:Literal></ogc:PropertyIsLike></ogc:Filter></wfs:Query></wfs:GetFeature>'
'http://localhost:8081/wms/test2?username=admin&cache_version=014489def2e244d48a7dcd581c565331'
-X POST -H 'Host: localhost' -H 'Content-Type: application/xml'

Answer:

<wfs:FeatureCollection xmlns:wfs="http://www.opengis.net/wfs"
xmlns:ogc="http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml"
xmlns:ows="http://www.opengis.net/ows"
xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:qgs="http://www.qgis.org/gml"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.opengis.net/wfs
http://schemas.opengis.net/wfs/1.0.0/wfs.xsd http://www.qgis.org/gml
http://testgmf.sig.cloud.camptocamp.net/test/wsgi/mapserv_proxy?SERVICE=WFS&VERSION=1.0.0&REQUEST=DescribeFeatureType&TYPENAME=borders&OUTPUTFORMAT=XMLSCHEMA
<http://testgmf.sig.cloud.camptocamp.net/test/wsgi/mapserv_proxy?SERVICE=WFS&VERSION=1.0.0&REQUEST=DescribeFeatureType&TYPENAME=borders&OUTPUTFORMAT=XMLSCHEMA>"><gml:boundedBy>
 <gml:Box srsName="EPSG:2154">
  <gml:coordinates cs="," ts=" ">-2180092.42950479,4708810.95456554
4283217.86913478,9600922.11590408</gml:coordinates>
 </gml:Box>
</gml:boundedBy>

But I should get one feature.

Thanks,

Y.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20160818/65400bb2/attachment.html>


More information about the Qgis-developer mailing list