Skip to content

Map using Google Maps Api Version 3. A comprehensible map can be displayed by using the custom marker.

Notifications You must be signed in to change notification settings

holyshared/MMap

Repository files navigation

MMap

Screenshot

Map using Google Maps Api Version 3. A comprehensible map can be displayed by using the custom marker.

How to use

MMap

Step1 Reading of library.

Mootools and MMap are added in the head element and read.

#HTML
<script type="text/javascript" src="http://maps.google.com/maps/api/js?v=3&amp;sensor=false"></script>
<script type="text/javascript" src="js/lib/mootools-core.js"></script>
<script type="text/javascript" src="js/lib/mmap-compressed.js"></script>

Step2 HTML description of main.

HTML to use MMap becomes as follows.

#HTML
<div id="map"></div>

Step3 Description of javascript.

#JS
(function($){

window.addEvent("domready", function(){

	var map = new google.maps.Map($('map'), {
		zoom: 15,
		center: new google.maps.LatLng(35.6666870, 139.731859),
		mapTypeId: google.maps.MapTypeId.ROADMAP
	});

	var marker = new MMap.Marker.HTML({
		map: map,
		className: 'marker markerDefault',
		title: 'Marker who contains simple contents',
		content: 'HTML contents can be inserted. <br />'
			+ 'It is usual to put sentences and photographs of several lines.',
		position: new google.maps.LatLng(35.6666870, 139.731859),
		visible: true
	});

});

}(document.id));

Online Document

Online Demonstration

About

Map using Google Maps Api Version 3. A comprehensible map can be displayed by using the custom marker.

Resources

Stars

Watchers

Forks

Packages

No packages published