Well, the log should be able to give you a clue as to what's going on.<br><br><br><div class="gmail_quote">On Thu, Nov 3, 2011 at 9:41 PM, Nicolas Ardissono <span dir="ltr"><<a href="mailto:nicolasardissono@yahoo.com.ar">nicolasardissono@yahoo.com.ar</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><u></u>
<div bgcolor="#ffffff" text="#000000">
So, the problem must be openlayers. If you can add and remove features
with qgis. I don't know where to look for.<br>
<br>
<br>
El 31/10/11 12:01, Gissur Þórhallsson escribió:
<blockquote type="cite"><div class="im">Hello Nicolas,<br>
<br>
What does the log on the server say? I've also found it very helpful to
also fiddle with the <b>log_level</b> parameters and see what pops out.<br>
Refer to <a href="http://www.tinyows.org/trac/wiki/ConfigFile" target="_blank">http://www.tinyows.org/trac/wiki/ConfigFile</a>
for how to configure logging.<br>
<br>
I can on the other hand verify that your WFS is working fine - since I
could connect to it from qgis and add/remove an island to the Faroe
Islands.<br>
<br>
Kind regards,<br>
Gissur<br>
<br>
</div><div class="gmail_quote"><div class="im">On Mon, Oct 31, 2011 at 3:41 AM, Nicolas
Ardissono <span dir="ltr"><<a href="mailto:nicolasardissono@yahoo.com.ar" target="_blank">nicolasardissono@yahoo.com.ar</a>></span>
wrote:<br>
</div><blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">
<div bgcolor="#ffffff" text="#000000"><div class="im">Hello, i'm a newy in this
matter, and after a week i have installed the
tinyows demo in my server (debian squeeze) and i could make it work,
all layers are showing, but i cannot make it save. <br>
<br>
Any tip or help will be apreciate. I don't know what else try, i have
no more ideas.<br>
<br>
When i edit same features and click save this is what <b>firebug post</b>:<br>
<br>
<wfs:Transaction xmlns:wfs=<a href="http://www.opengis.net/wfs" target="_blank">"http://www.opengis.net/wfs"</a>
service="WFS" version="1.1.0"
xsi:schemaLocation=<a href="http://www.opengis.net/wfshttp://schemas.opengis.net/wfs/1.1.0/wfs.xsdhttp://www.agpstracking.com/http://www.agpstracking.com/cgi-bin/tinyows?service=wfs&request=DescribeFeatureType&version=1.1.0&typename=france" target="_blank">"http://www.opengis.net/wfs
http://schemas.opengis.net/wfs/1.1.0/wfs.xsd
http://www.agpstracking.com/
http://www.agpstracking.com/cgi-bin/tinyows?service=wfs&request=DescribeFeatureType&version=1.1.0&typename=france"</a>
xmlns:xsi=<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">"http://www.w3.org/2001/XMLSchema-instance"</a>><br>
<wfs:Update typeName="feature:france"
xmlns:feature=<a href="http://www.agpstracking.com/" target="_blank">"http://www.agpstracking.com/"</a>><br>
<wfs:Property><br>
<wfs:Name>the_geom</wfs:Name><br>
<wfs:Value><br>
<gml:MultiSurface xmlns:gml=<a href="http://www.opengis.net/gml" target="_blank">"http://www.opengis.net/gml"</a>
srsName="EPSG:27582"><br>
<gml:surfaceMember><br></div><div><div></div><div class="h5">
<ogc:Filter xmlns:ogc=<a href="http://www.opengis.net/ogc" target="_blank">"http://www.opengis.net/ogc"</a>><br>
<ogc:FeatureId></ogc:FeatureId><br>
</ogc:Filter><br>
</wfs:Update><br>
</wfs:Transaction><br>
<br>
<br>
<b>this is the tinyows response in firebug:</b><br>
<pre><code><?xml version='1.0' encoding='UTF-8'?>
</code><code><ows:ExceptionReport
</code><code> xmlns='<a href="http://www.opengis.net/ows" target="_blank">http://www.opengis.net/ows</a>'
</code><code> xmlns:ows='<a href="http://www.opengis.net/ows" target="_blank">http://www.opengis.net/ows</a>'
</code><code> xmlns:xsi='<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>'
</code><code> xsi:schemaLocation='<a href="http://www.opengis.net/ows" target="_blank">http://www.opengis.net/ows</a> <a href="http://schemas.opengis.net/ows/1.0.0/owsExceptionReport" target="_blank">http://schemas.opengis.net/ows/1.0.0/owsExceptionReport</a></code><code>.xsd'
</code><code> version='1.1.0' language='en'>
</code><code> <ows:Exception exceptionCode='InvalidParameterValue' locator='request'>
</code><code> <ows:ExceptionText>XML request isn't valid</ows:ExceptionText>
</code><code> </ows:Exception>
</code><code></ows:ExceptionReport></code></pre>
<br>
<br>
This is what i have in: <br>
<b>/etc/tinyows.xml:</b><br>
<tinyows
online_resource=<a href="http://www.agpstracking.com/cgi-bin/tinyows" target="_blank">"http://www.agpstracking.com/cgi-bin/tinyows"</a><br>
schema_dir="/usr/local/share/tinyows/schema/" log_level="1"
log="/var/log/tinyows.log"><br>
<br>
<pg host="127.0.0.1" user="remise" password="12346"
dbname="tinyows_demo" port="5433"/><br>
<br>
<metadata name="TinyOWS Server"<br>
title="TinyOWS Server - Demo Service" /><br>
<br>
<layer retrievable="1"<br>
writable="1"<br>
ns_prefix="tows"<br>
ns_uri=<a href="http://www.agpstracking.com/" target="_blank">"http://www.agpstracking.com/"</a><br></div></div><div><div></div><div class="h5">
name="france"<br>
server=<a href="http://www.agpstracking.com/" target="_blank">"http://www.agpstracking.com/"</a><br>
title="French Administrative Sub Boundaries (IGN - GeoFLA
Departements)" /><br>
<br>
</tinyows><br>
<br>
<br>
<b>this is the javascript file:</b><br>
<br>
var map, wfs;<br>
<br>
var DeleteFeature = OpenLayers.Class(OpenLayers.Control, {<br>
initialize: function(layer, options) {<br>
OpenLayers.Control.prototype.initialize.apply(this, [options]);<br>
this.layer = layer;<br>
this.handler = new OpenLayers.Handler.Feature(<br>
this, layer, {click: this.clickFeature}<br>
);<br>
},<br>
clickFeature: function(feature) {<br>
// if feature doesn't have a fid, destroy it<br>
if(feature.fid == undefined) {<br>
this.layer.destroyFeatures([feature]);<br>
} else {<br>
feature.state = OpenLayers.State.DELETE;<br>
this.layer.events.triggerEvent("afterfeaturemodified", <br>
{feature: feature});<br>
feature.renderIntent = "select";<br>
this.layer.drawFeature(feature);<br>
}<br>
},<br>
setMap: function(map) {<br>
this.handler.setMap(map);<br>
OpenLayers.Control.prototype.setMap.apply(this, arguments);<br>
},<br>
CLASS_NAME: "OpenLayers.Control.DeleteFeature"<br>
});<br>
<br>
<br>
<br>
function showMsg(szMessage) {<br>
window.alert(szMessage);<br>
/*document.getElementById("message").innerHTML = szMessage;<br>
setTimeout(<br>
"document.getElementById('message').innerHTML = ''",2000);*/<br>
};<br>
<br>
function showSuccessMsg(){<br>
showMsg("Transaction successfully completed");<br>
};<br>
<br>
function showFailureMsg(){<br>
showMsg("An error occured while operating the transaction");<br>
};<br>
<br>
<br>
function init() {<br>
map = new OpenLayers.Map('basicMap', {<br>
projection: new OpenLayers.Projection("EPSG:27582"),<br>
units: "m",<br>
maxResolution: "auto",<br>
maxExtent: new OpenLayers.Bounds(5000,1620000,1198000,2678000),<br>
controls: [<br>
new OpenLayers.Control.PanZoom()<br>
]<br>
});<br>
var base = new OpenLayers.Layer.WMS("OpenLayers WMS",<br>
<a href="http://www.geosignal.org/cgi-bin/wmsmap?" target="_blank">"http://www.geosignal.org/cgi-bin/wmsmap?"</a>,<br>
{layers: "Regions,Departements",<br>
projection:"EPSG:27582",<br>
displayProjection: new OpenLayers.Projection("EPSG:27582"),<br>
units: "m",<br>
maxResolution: "auto",<br>
maxExtent: new OpenLayers.Bounds(5000,1620000,1198000,2678000),<br>
sld:
<a href="http://www.tinyows.org/tracdocs/demo/OpenLayers-2.9/examples/sld.xml" target="_blank">"http://www.tinyows.org/tracdocs/demo/OpenLayers-2.9/examples/sld.xml"</a><br>
}<br>
);<br>
<br>
map.addLayer(base);<br>
<br>
var saveStrategy = new OpenLayers.Strategy.Save();<br>
saveStrategy.events.register("success", '', showSuccessMsg);<br>
saveStrategy.events.register("fail", '', showFailureMsg);<br>
<br>
wfs = new OpenLayers.Layer.Vector("Editable Features", {<br>
strategies: [new OpenLayers.Strategy.BBOX(), saveStrategy],<br>
projection: new OpenLayers.Projection("EPSG:27582"),<br>
protocol: new OpenLayers.Protocol.WFS({<br>
version: "1.1.0",<br>
srsName: "EPSG:27582",<br>
url: <a href="http://www.agpstracking.com/cgi-bin/tinyows?" target="_blank">"http://www.agpstracking.com/cgi-bin/tinyows?"</a>,<br>
featureType: "france",<br>
featureNS: <a href="http://www.agpstracking.com/" target="_blank">"http://www.agpstracking.com/"</a>,<br>
geometryName: "the_geom",<br>
schema:
<a href="http://www.agpstracking.com/cgi-bin/tinyows?service=wfs&request=DescribeFeatureType&version=1.1.0&typename=france" target="_blank">"http://www.agpstracking.com/cgi-bin/tinyows?service=wfs&request=DescribeFeatureType&version=1.1.0&typename=france"</a>,<br>
outputFormat: "application/json",<br>
readFormat: new OpenLayers.Format.GeoJSON()<br>
})<br>
});<br>
<br>
map.addLayer(wfs);<br>
<br>
var panel = new OpenLayers.Control.Panel(<br>
{'displayClass': 'customEditingToolbar'}<br>
);<br>
<br>
var navigate = new OpenLayers.Control.Navigation({<br>
title: "Pan Map"<br>
});<br>
<br>
var draw = new OpenLayers.Control.DrawFeature(<br>
wfs, OpenLayers.Handler.Polygon,<br>
{<br>
title: "Draw Feature",<br>
displayClass: "olControlDrawFeaturePolygon",<br>
multi: true<br>
}<br>
);<br>
<br>
var edit = new OpenLayers.Control.ModifyFeature(wfs, {<br>
title: "Modify Feature",<br>
displayClass: "olControlModifyFeature"<br>
});<br>
<br>
var del = new DeleteFeature(wfs, {title: "Delete Feature"});<br>
<br>
var save = new OpenLayers.Control.Button({<br>
title: "Save Changes",<br>
trigger: function() {<br>
if(edit.feature) {<br>
edit.selectControl.unselectAll();<br>
}<br>
saveStrategy.save();<br>
},<br>
displayClass: "olControlSaveFeatures"<br>
});<br>
<br>
panel.addControls([navigate, save, edit, draw, del]);<br>
panel.defaultControl = navigate;<br>
map.addControl(panel);<br>
map.zoomToMaxExtent();<br>
<br>
}<br>
<br>
<br>
<b>this is my html file:</b><br>
<br>
<html><br>
<head><br>
<LINK REL=StyleSheet HREF='../estilo.css' TYPE='text/css'><br>
<link rel="stylesheet" href="theme/default/style.css"
type="text/css" /><br>
<script src="OpenLayers-2.9/OpenLayers.js"></script><br></div></div><div><div></div><div class="h5">
<script src="tinyows_wfs-t.js"></script><br>
</head><br>
<br>
<body onload="init()"><br>
<h1 id="title">WFS Transaction Example, (TinyOWS ans
OpenLayers)</h1><br>
<div id="tags"></div><br>
<p id="shortdesc"><br>
Shows the use of the WFS Transactions (WFS-T).<br>
Parks of Osnabruck (Frida).<br>
<br /><br>
Base layers is OpenStreetMap from Omniscale WMS Server.<br>
</p><br>
<div id="basicMap"></div><br>
<br>
<div id="message"></div><br>
<div id="docs"><br>
<p><br>
The WFS protocol allows for creation of new features and<br>
reading, updating, or deleting of existing features.<br>
</p><br>
<p><br>
Use the tools to create, modify, and delete (in order
from left<br>
to right) features. Use the save tool (picture of a
disk) to<br>
save your changes. Use the navigation tool (hand) to
stop<br>
editing and use the mouse for map navigation.<br>
</p><br>
<p><br>
See the <a href="tinyows_wfs-t.js"
target="_blank"><br>
<br>
wfs-protocol-transactions.js source</a> to see
how this is done.<br>
</p> <br>
</div><br>
</body><br>
</html><br>
<br>
THANKS<br>
</div></div></div><div><div></div><div class="h5">
<br>
_______________________________________________<br>
TinyOWS-users mailing list<br>
<a href="mailto:TinyOWS-users@lists.maptools.org" target="_blank">TinyOWS-users@lists.maptools.org</a><br>
<a href="http://lists.maptools.org/mailman/listinfo/tinyows-users" target="_blank">http://lists.maptools.org/mailman/listinfo/tinyows-users</a><br>
<br>
</div></div></blockquote>
</div><div><div></div><div class="h5">
<br>
<br clear="all">
<br>
-- <br>
Gissur Þórhallsson<br>
<br>
Loftmyndir ehf.<br>
Laugavegur 13<br>
IS 101 Reykjavík - Iceland<br>
sími (tel): <a href="tel:%28%2B354%29%20540%202500" value="+3545402500" target="_blank">(+354) 540 2500</a><br>
tölvupóstur (email): <a href="mailto:gissur@loftmyndir.is" target="_blank">gissur@loftmyndir.is</a><br>
<pre><fieldset></fieldset>
_______________________________________________
TinyOWS-users mailing list
<a href="mailto:TinyOWS-users@lists.maptools.org" target="_blank">TinyOWS-users@lists.maptools.org</a>
<a href="http://lists.maptools.org/mailman/listinfo/tinyows-users" target="_blank">http://lists.maptools.org/mailman/listinfo/tinyows-users</a>
</pre>
</div></div></blockquote>
<br>
</div>
<br>_______________________________________________<br>
TinyOWS-users mailing list<br>
<a href="mailto:TinyOWS-users@lists.maptools.org">TinyOWS-users@lists.maptools.org</a><br>
<a href="http://lists.maptools.org/mailman/listinfo/tinyows-users" target="_blank">http://lists.maptools.org/mailman/listinfo/tinyows-users</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Gissur Þórhallsson<br><br>Loftmyndir ehf.<br>Laugavegur 13<br>IS 101 Reykjavík - Iceland<br>sími (tel): (+354) 540 2500<br>tölvupóstur (email): <a href="mailto:gissur@loftmyndir.is">gissur@loftmyndir.is</a><br>