Hi,

It seems to be a projection error. Your data come in EPSG:4326 (-180 - 180,
-90 - 90), that's in sphericalMercator equal 0,0 near Africa.

I would think, that you use map.projection sphericalMercator and for
map.displayProjection also sphericalMercator. 

Set in the layer declaration projection: "EPSG:4326" and your data should be
at the right place.

Arnd

-----Ursprüngliche Nachricht-----
Von: users-boun...@openlayers.org [mailto:users-boun...@openlayers.org] Im
Auftrag von Dirk Wimmer
Gesendet: Mittwoch, 5. Mai 2010 23:45
An: users@openlayers.org
Betreff: [OpenLayers-Users] kml-files doesn't shown correct

Hello,

I have problem to use this kml file with openlayers:
http://www.dav-felsinfo.de/export/cliffs_kml.php?1=22

E.g. I use this example
http://www.openlayers.org/dev/examples/sundials.html and change only a
little bit:

            var sundials = new OpenLayers.Layer.Vector("KML", {
                projection: map.displayProjection,
                strategies: [new OpenLayers.Strategy.Fixed()],
                protocol: new OpenLayers.Protocol.HTTP({
                    url:
"http://www.dav-felsinfo.de/export/cliffs_kml.php?1=22";,
                    format: new OpenLayers.Format.KML({
                        extractStyles: true,
                        extractAttributes: true
                    })
                })


Then I see only one icon in the sea nearby Africa and not in Germany. :-(

But the result should looks like that:
http://maps.google.de/maps?f=q&hl=de&q=http://www.dav-felsinfo.de/export/cli
ffs_kml.php?1=22

I try some other kml files and it works.
Could it be that this kml file is incorrect?
Any ideas?

thanks,
Dirk
_______________________________________________
Users mailing list
Users@openlayers.org
http://openlayers.org/mailman/listinfo/users

_______________________________________________
Users mailing list
Users@openlayers.org
http://openlayers.org/mailman/listinfo/users

Reply via email to