Advertisement
Guest User

Untitled

a guest
Jul 19th, 2014
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.68 KB | None | 0 0
  1. <!DOCTYPE html >
  2. <html>
  3. <head>
  4. <meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  6. <style type="text/css">
  7. body {
  8. font-family: Helvetica, Arial, sans-serif;
  9. font-size:10px;
  10. margin:0;
  11. }
  12.  
  13. #content {
  14.  
  15. }
  16. </style>
  17.  
  18. <script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyASm3CwaK9qtcZEWYa-iQwHaGi3gcosAJc&sensor=false"></script>
  19. <script type="text/javascript">
  20. function initialize() {
  21. var latlng = new google.maps.LatLng(44.80382751970516, 20.467684831491056);
  22. var settings = {
  23. zoom: 16,
  24. center: latlng,
  25. mapTypeControl: true,
  26. mapTypeControlOptions: {style: google.maps.MapTypeControlStyle.DROPDOWN_MENU},
  27. navigationControl: true,
  28. navigationControlOptions: {style: google.maps.NavigationControlStyle.SMALL},
  29. mapTypeId: google.maps.MapTypeId.ROATERDMAP,
  30. styles: [
  31. {
  32. "featureType": "landscape",
  33. "elementType": "labels",
  34. "stylers": [
  35. {
  36. "visibility": "off"
  37. }
  38. ]
  39. },
  40. {
  41. "featureType": "transit",
  42. "elementType": "labels",
  43. "stylers": [
  44. {
  45. "visibility": "off"
  46. }
  47. ]
  48. },
  49. {
  50. "featureType": "poi",
  51. "elementType": "labels",
  52. "stylers": [
  53. {
  54. "visibility": "off"
  55. }
  56. ]
  57. },
  58. {
  59. "featureType": "water",
  60. "elementType": "labels",
  61. "stylers": [
  62. {
  63. "visibility": "off"
  64. }
  65. ]
  66. },
  67. {
  68. "featureType": "road",
  69. "elementType": "labels.icon",
  70. "stylers": [
  71. {
  72. "visibility": "off"
  73. }
  74. ]
  75. },
  76. {
  77. "stylers": [
  78. {
  79. "hue": "#00aaff"
  80. },
  81. {
  82. "saturation": -100
  83. },
  84. {
  85. "gamma": 2.15
  86. },
  87. {
  88. "lightness": 12
  89. }
  90. ]
  91. },
  92. {
  93. "featureType": "road",
  94. "elementType": "labels.text.fill",
  95. "stylers": [
  96. {
  97. "visibility": "on"
  98. },
  99. {
  100. "lightness": 24
  101. }
  102. ]
  103. },
  104. {
  105. "featureType": "road",
  106. "elementType": "geometry",
  107. "stylers": [
  108. {
  109. "lightness": 57
  110. }
  111. ]
  112. }
  113. ]
  114.  
  115.  
  116.  
  117. };
  118. var map = new google.maps.Map(document.getElementById("map_canvas"), settings);
  119. var contentString = '<div id="content">'+
  120. '<div id="siteNotice">'+
  121. '</div>'+
  122. '<h1 id="firstHeading" class="firstHeading">Company Name</h1>'+
  123. '<div id="bodyContent">'+
  124. '<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>'+
  125. '</div>'+
  126. '</div>';
  127. var infowindow = new google.maps.InfoWindow({
  128. content: contentString
  129. });
  130.  
  131. var companyImage = new google.maps.MarkerImage('http://dryicons.com/images/icon_sets/colorful_stickers_icons_set/png/128x128/comment.png',
  132. new google.maps.Size(200,200),
  133. new google.maps.Point(0,0),
  134. new google.maps.Point(0,0)
  135. );
  136.  
  137.  
  138.  
  139. var companyPos = new google.maps.LatLng(44.80382751970516, 20.467684831491056);
  140.  
  141. var companyMarker = new google.maps.Marker({
  142. position: companyPos,
  143. map: map,
  144. icon: companyImage,
  145.  
  146. title:"Company",
  147. zIndex: 3});
  148.  
  149.  
  150.  
  151.  
  152. google.maps.event.addListener(companyMarker, 'click', function() {
  153. infowindow.open(map,companyMarker);
  154. });
  155. }
  156. </script>
  157.  
  158. </head>
  159. <body onload="initialize()">
  160. <div id="map_canvas" style="width:100%; height:500px"></div>
  161. </body>
  162. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement