javascript - How do I create a constantly updating Geojson server? -
i using leaflet api. coded out map , have code geojson map. don't know code need create on other server. want leaflet api/my code able pull location other server onto map in real time. want use same basic code website doing: http://www.tagkartan.se/
here basic example of code:
var map = l.map('map'), realtime = l.realtime({ url: 'https://wanderdrone.appspot.com/', crossorigin: true, type: 'json' }, { interval: 3 * 1000 }).addto(map); realtime.on('update', function() { map.fitbounds(realtime.getbounds(), {maxzoom: 3}); });
^^but pulling wanderdrone.appspot.com website. how set own website pull location many different phones @ on time , have them sync in real time on map? know need little javascript/html after that. don't understand how pull location 1 server , have leaflet map replicate location on map. in advance!
Comments
Post a Comment