[OpenLayers-Users] OpenLayers.Request.POST
Eric Lemoine
eric.c2c at gmail.com
Tue Jul 22 11:51:19 EDT 2008
Question: does it work better without the Content-Type header?
Eric
2008/7/18, Fabio D'Ovidio <fabiodovidio at gmail.com>:
> Hello,
> I'm trying to pass some values using POST method and OpenLayers.Request
> as following:
> // POST
> var data = this.idOperazione(); //my function returns my values
> to pass
> var url = "myUrl";
> var request = OpenLayers.Request.POST({
> url: url,
> data: data,
> headers: {
> "Content-Type": "application-xml"
> },
> callback: handler
> });
>
> I have an error in using it...
> uncaught exception: [Exception... "Component returned failure code:
> 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXMLHttpRequest.send]" nsresult:
> "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: javascript:
> eval(__firebugTemp__); :: anonymous :: line 1" data: no]
>
> My aim is to pass values in POST to the URL that must generate GML (
>
> var new1 = new OpenLayers.Layer.GML("GeoRSS", url , {format:
> OpenLayers.Format.GeoRSS});
>
> map.addLayers([new1]);
>
> )
>
> Thanks
>
>
> --
> Ing. Fabio D'Ovidio
>
> INOVA Open Solutions s.r.l.
> Web : http://www.inovaos.it
> Tel.: 081 197 57 600
> mail: fabiodovidio at gmail.com
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
More information about the Users
mailing list