Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
An example of using Google Map tiles with the Leaflet mapping library - Forked from, updated to use leaflet CDN (fixes 403 forbidden)
<!DOCTYPE html>
<link rel="stylesheet" href="" />
<script src=""></script>
<script src=""></script>
<script src=""></script>
<div style="width:500px; height:500px" id="map"></div>
<script type='text/javascript'>
var map = new L.Map('map', {center: new L.LatLng(51.51, -0.11), zoom: 9});
var googleLayer = new L.Google('ROADMAP');

This comment has been minimized.

Copy link

@digithebest digithebest commented Dec 11, 2013

It works fine but I am experiencing problem with adding the marker. When I add the circle marker it is not visible on the map. Could you please help me with it? Thanks


This comment has been minimized.

Copy link

@dhirajt dhirajt commented Feb 24, 2014

@digithebest add these lines to your page
.leaflet-map-pane {
z-index: 2 !important;

.leaflet-google-layer {
z-index: 1 !important;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment