I'm embeding a MapBox map in my html page via mapbox.js script like so:
L.mapbox.accessToken = 'pk.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.xxxxxxxxxxxxxxxxxxxxxx';
var map = L.mapbox.map('map', 'xxxxx.xxxxxxxx', {
zoomControl: false
});
This produces a map like this: http://s4.postimg.org/58m4aeb8d/mapbox.png
How do I remove "Mapbox" logo in the bottom left corner?
You can only completely remove the attribution on maps that do not contain Mapbox (Streets, Terrain, Satellite) or OpenStreetMap layers. This is because the OpenStreetMap and DigitalGlobe data contained in these layers legally require attribution.
If your map doesn’t include these layers, you can remove the default attribution by setting the info control to false:
var map = L.mapbox.map('map', 'examples.map-8ced9urs', {attributionControl: false});
You can add your own attribution by using the L.control.attribution constructor.
var credits = L.control.attribution().addTo(map);
credits.addAttribution('Credits: Penny Dog Mapping Co.');
You can, however, move the attribution. If you are using a layer that requires attribution, but want to move it to a different part of the page, you can insert this HTML snippet elsewhere on the page, like a page footer:
<a href='https://www.mapbox.com/about/maps/' target='_blank'>Maps © Mapbox © OpenStreetMap</a>
This may violate the MapBox terms of service. Adding this css will remove it...
.mapbox-logo{
display: none !important;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With