You are not logged in.

Announcement

*** NOTICE: forum.openstreetmap.org is being retired. Please request a category for your community in the new ones as soon as possible using this process, which will allow you to propose your community moderators.
Please create new topics on the new site at community.openstreetmap.org. We expect the migration of data will take a few weeks, you can follow its progress here.***

#26 2011-12-15 12:48:00

Nitram
Member
Registered: 2011-05-03
Posts: 5

Re: Leaflet — a new open source JavaScript library for maps by CloudMade

Thank you for your answer.

When i Click one time on the "Permalink" link, after i zoomed, here is the URL show for example in URL bar : http://www.lavilleavelo.org/carte/lvv2. … on=4.84909

And the map is not show.

But when i click a second time on "Permalink" link, the URL change : http://www.lavilleavelo.org/carte/lvv2. … -175.15091 and the Permalink is  good. In fact, only the longitude change, and i dont understand at all. The right value for longitude is in the first URL but this is the second value (-175.15091 for example) which works.

When i add this line : map.setView(new L.LatLng(lat, lon), zoom).addLayer(cloudmade);
it doent work.

Offline

#27 2011-12-16 13:57:57

greencaps
Member
Registered: 2009-10-05
Posts: 423

Re: Leaflet — a new open source JavaScript library for maps by CloudMade

If this was OpenLayers you could use something like:
   
var lon = 16831422;
      var lat=-4012608;
    var zoom = 3;

            if(!map.getCenter())
                map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);

You could try the GetCenter() (a lot of functions in leaflet seem to have the same names).

Offline

#28 2011-12-16 14:52:18

chris66
Member
From: Germany
Registered: 2009-05-24
Posts: 10,107

Re: Leaflet — a new open source JavaScript library for maps by CloudMade

Hi,
do I understand correctly that leaflet is somethink like openlayers ?

Can it do more than OL or what are the advantages ?

Chris


Mapper aus dem Münsterland.

Offline

#29 2011-12-16 17:30:39

greencaps
Member
Registered: 2009-10-05
Posts: 423

Re: Leaflet — a new open source JavaScript library for maps by CloudMade

Yes.

Chris please read the first post in this thread by Mourner and follow the link(s).

Offline

#30 2011-12-30 09:19:50

Nitram
Member
Registered: 2011-05-03
Posts: 5

Re: Leaflet — a new open source JavaScript library for maps by CloudMade

Thank you green caps. I have actually reinstall OpenLayers for the moment, in order to find the problem (and another).

Offline

#31 2013-02-17 19:09:07

StefanoCudini
Member
Registered: 2013-02-17
Posts: 1

Re: Leaflet — a new open source JavaScript library for maps by CloudMade

hello

I think that leaflet is an excellent and simple web mapping library and now there are many plugins that have been developed
pointing you to a couple of two very useful plugins that I developed with the help of other programmers on github:

http://labs.easyblog.it/maps/leaflet-search/
http://labs.easyblog.it/maps/leaflet-gps/

Offline

Board footer

Powered by FluxBB