$(document).ready(function(){
  L.mapbox.accessToken = '<%= ENV['MAPBOX_KEY'] %>';
  var map = L.mapbox.map('map', 'mapbox.dark').setView([39.114102, -94.627478], 5);

  var data = [
  { name: 'Location A', category: 'Store', street: 'Market', lat: 39.984, lng: -75.343 },
  { name: 'Location B', category: 'House', street: 'Broad', lat: 39.284, lng: -75.833 },
  { name: 'Location C', category: 'Office', street: 'South', lat: 39.123, lng: -74.534 }
  ];

  var geojson_objects = GeoJSON.parse(data, {Point: ['lat', 'lng']});

  var myLayer = L.mapbox.featureLayer().addTo(map);
  myLayer.on('layeradd', function(e){
    var marker = e.layer;
    feature = marker.feature;
    var content = '<h2>'+ feature.properties.name+'<\/h2>' + '<p>'+feature.properties.category+'</p><a href="http://www.google.com">ClickMe</a>';
    marker.bindPopup(content);
  });

  myLayer.setGeoJSON(geojson_objects);

});


$(document).ready(function(){
  L.mapbox.accessToken = '<%= ENV['MAPBOX_KEY'] %>';
  var map = L.mapbox.map('map', 'mapbox.dark').setView([39.114102, -94.627478], 5);

  var data = [
  { city: "San Francisco", temp: "98.3", latitude: 39.984, longitude: -75.343 },
  { city: "San Francisco", temp: "98.7", latitude: 39.284, longitude: -75.833 },
  { city: "San Francisco", temp: "98.5", latitude: 39.123, longitude: -74.534 }
  ];

  var geojson_objects = GeoJSON.parse(data, {Point: ['latitude', 'longitude']});

  var myLayer = L.mapbox.featureLayer().addTo(map);
  myLayer.on('layeradd', function(e){
    var marker = e.layer;
    feature = marker.feature;
    var content = '<h2><a href="http://www.google.com">'+ feature.properties.city+'</a></h2><p>'+feature.properties.temp+'</p>';
    marker.bindPopup(content);
  });

  myLayer.setGeoJSON(geojson_objects);

});


Change display information of test points
Change display information of test points
