NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

I have a basic map created by mapbox with the code below and want input markercluster function, anybody can complete the code for me.Thanks a ton!

<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title></title>
  <script src='http://api.tiles.mapbox.com/mapbox.js/v1.6.2/mapbox.js'></script>
  <link href='http://api.tiles.mapbox.com/mapbox.js/v1.6.2/mapbox.css' rel='stylesheet' />
  <!--[if lte IE 8]>
    <link href='//api.tiles.mapbox.com/mapbox.js/v1.6.2/mapbox.ie.css' rel='stylesheet'>
  <![endif]-->
  <style>
    body { margin:0; padding:0; }
    #map { position:absolute; top:0; bottom:0; width:100%; }
  </style>
</head>
<body>
<div id='map'></div>
<script type='text/javascript'>
var map = L.mapbox.map('map', 'zjmu916.map-47p7qt6u');

var featureLayer = L.mapbox.featureLayer('zjmu916.map-47p7qt6u',{ 
  sanitizer: function(x) { 
    return x; }
  }).addTo(map);

</script>
</body>
</html>

asked 09 Apr '14, 19:30

zjmu916's gravatar image

zjmu916
1555
accept rate: 0%

edited 10 Apr '14, 07:21

scai's gravatar image

scai ♦
33.3k21309459

1

This portal is focused on OSM only. You might want to repost your question over at gis.stackoverflow.com as more devs lurk there. But before you do so, you might want to give it a try on your own: https://www.mapbox.com/mapbox.js/example/v1.0.0/leaflet-markercluster/ and then post where you fail.

(09 Apr '14, 20:56) iii

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×362
×74
×40

question asked: 09 Apr '14, 19:30

question was seen: 5,859 times

last updated: 10 Apr '14, 07:21

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum