here is my jsfiddle link http://jsfiddle.net/tridip/5abu963o/. i made provision so a yellow color text should be lying on map but not working.
here is the js part only i like to highlight.
$( document ).ready(function() { var map = L.map('map').setView([49.2, 16.5], 10); new L.TileLayer('http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(map); L.marker(new L.LatLng(49.2, 16.5), {icon:createLabelIcon("textLabelclass","a place")}).addTo(map); L.marker(new L.LatLng(49.25, 16.4), {icon:createLabelIcon("textLabelclass","another place")}).addTo(map); L.marker(new L.LatLng(49.15, 16.37), {icon:createLabelIcon("textLabelclass","place 3")}).addTo(map); L.marker(new L.LatLng(49.21, 16.38), {icon:createLabelIcon("textLabelclass","place 4")}).addTo(map);})var createLabelIcon = function(labelClass,labelText){ return L.divIcon({ className: labelClass, html: labelText })}
أكثر...
here is the js part only i like to highlight.
$( document ).ready(function() { var map = L.map('map').setView([49.2, 16.5], 10); new L.TileLayer('http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(map); L.marker(new L.LatLng(49.2, 16.5), {icon:createLabelIcon("textLabelclass","a place")}).addTo(map); L.marker(new L.LatLng(49.25, 16.4), {icon:createLabelIcon("textLabelclass","another place")}).addTo(map); L.marker(new L.LatLng(49.15, 16.37), {icon:createLabelIcon("textLabelclass","place 3")}).addTo(map); L.marker(new L.LatLng(49.21, 16.38), {icon:createLabelIcon("textLabelclass","place 4")}).addTo(map);})var createLabelIcon = function(labelClass,labelText){ return L.divIcon({ className: labelClass, html: labelText })}
أكثر...