html http://jquery-ui-map.googlecode.com/svn/trunk/demos/jquery-google-maps-geolocation.html

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了html http://jquery-ui-map.googlecode.com/svn/trunk/demos/jquery-google-maps-geolocation.html相关的知识,希望对你有一定的参考价值。

<!doctype html> 
<html lang="en">
   <head>
  	<title>Google maps and geolocation - Google maps jQuery plugin</title>
		<meta charset="utf-8" />
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
		<meta http-equiv="content-language" content="en" />
		<meta name="viewport" content="width=device-width,initial-scale=1" />
		<meta name="keywords" content="Google maps, jQuery, plugin, Geolocation, Geo positioning" />
		<meta name="description" content="An example with jQuery, Google Maps and geolocation using Google maps jQuery plugin" />

		
		<link rel="stylesheet" type="text/css" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/ui-lightness/jquery-ui.css" />

		<link type="text/css" rel="stylesheet" href="css/style.css" />

    </head>
    <body>
		<header class="dark">

		</header>
		<div class="container_16">
			<article class="grid_16">
				<div class="item rounded dark">
					<div id="map_canvas" class="map rounded"></div>
				</div>
			</article>
		</div>

		<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script> 
		<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>
		<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"></script>
	
		<script type="text/javascript" src="js/demo.js"></script>
		<script type="text/javascript" src="ui/jquery.ui.map.js"></script>
		<script type="text/javascript" src="ui/jquery.ui.map.overlays.js"></script>
		<!--the getCurrentPosition is an extension of the plugin. Most likely you haven't included jquery-ui-map-extensions.js-->
		<script type="text/javascript" src="ui/jquery.ui.map.extensions.js"></script>
		<script type="text/javascript">
            $(function() { 
				demo.add(function() {
					$('#map_canvas').gmap({ 'disableDefaultUI':true, 'callback': function() {
						var self = this;
						self.getCurrentPosition(function(position, status) {
							if ( status === 'OK' ) {

				
								self.set('clientPosition', new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
								self.addMarker({'position': self.get('clientPosition'), 'bounds': true});
								var zoom = $('#map_canvas').gmap('option', 'zoom');
								$('#map_canvas').gmap('option', 'zoom', 15); //改變檢視層級
								
								self.addShape('Circle', { 'strokeWeight': 0, 'fillColor': "#008595", 'fillOpacity': 0.25, 'center': self.get('clientPosition'), 'radius': 300, clickable: false });//畫半徑300m的圈
							}
						});   
					}});
				}).load();
			});
        </script>
    
	</body>
</html>

以上是关于html http://jquery-ui-map.googlecode.com/svn/trunk/demos/jquery-google-maps-geolocation.html的主要内容,如果未能解决你的问题,请参考以下文章

Html.Partial 与 Html.RenderPartial 和 Html.Action 与 Html.RenderAction

html Html模板/ Html Boilerplate |标签HTML

html里怎么引用一个html的头部

html5与传统html区别

html4和html5的区别

HTML元素