[OpenLayers-Users] Problem with gml layer.

Eric Lemoine eric.c2c at gmail.com
Wed Jun 25 09:13:40 EDT 2008


On Wed, Jun 25, 2008 at 2:52 PM, David Martinez Morata
<damarmo at gmail.com> wrote:
> Hello,
> I try to put this layer in a map but...
>
> map.addLayer(new OpenLayers.Layer.GML("GML",
>
> "http://10.192.160.133/OpenLayers/ngo9_wgs84_01meu_cables_lille32.gml",
>             {format: OpenLayers.Format.KML},
>             {formatOptions: {
>               extractAttributes: true,
>               internalProjection: new OpenLayers.Projection('EPSG:900913'),
>               externalProjection: new OpenLayers.Projection('EPSG:4326')}
>               }
>                )
>                    );
> I don't have a graphical image of the elements!!!
> You have a sugestion?

The format and formatOptions options should be in the same object. And
that object should be passed as the third argument to the GML layer
constructor.

--
Eric



More information about the Users mailing list