Advertisement
Guest User

Untitled

a guest
Apr 2nd, 2016
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 4.17 KB | None | 0 0
  1. <html xmlns="http://www.w3.org/1999/xhtml">
  2.   <head>
  3.     <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
  4.     <title>gps system</title>
  5.     <script src="http://maps.google.com/maps/api/js?sensor=false" type="text/javascript"></script>
  6.     <link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">
  7.       <script src="//code.jquery.com/jquery-1.10.2.js"></script>
  8.       <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script>
  9.       <link rel="stylesheet" href="/resources/demos/style.css">
  10.       <script>
  11.       $(function() {
  12.          
  13.     jQuery(function($){
  14.     $.datepicker.regional['pl'] = {
  15.         closeText: 'Zamknij',
  16.         prevText: '&#x3c;Poprzedni',
  17.         nextText: 'Następny&#x3e;',
  18.         currentText: 'Dziś›',
  19.         monthNames: ['Styczeń„','Luty','Marzec','Kwiecień„','Maj','Czerwiec',
  20.         'Lipiec','SierpieĹń','Wrzesień„','Październik','Listopad','GrudzieĹń'],
  21.         monthNamesShort: ['Sty','Lu','Mar','Kw','Maj','Cze',
  22.         'Lip','Sie','Wrz','Pa','Lis','Gru'],
  23.         dayNames: ['Niedziela','Poniedziałek','Wtorek','Śšroda','Czwartek','Pią…tek','Sobota'],
  24.         dayNamesShort: ['Nie','Pn','Wt','Śšr','Czw','Pt','So'],
  25.         dayNamesMin: ['N','Pn','Wt','Śr','Cz','Pt','So'],
  26.         dateFormat: 'yy-mm-dd', firstDay: 1,
  27.         isRTL: false};
  28.     $.datepicker.setDefaults($.datepicker.regional['pl']);
  29. });
  30.  
  31.         /*  
  32.         setInterval(function(){cache_clear()},3000);
  33.          function cache_clear()
  34.         {
  35.          window.location.reload(true);
  36.         }
  37.         */
  38.          
  39.         $('#datepicker').datepicker();
  40.           $.datepicker.setDefaults(
  41.               $.extend(
  42.                 {'dateFormat':'yy-mm-dd'},
  43.                 $.datepicker.regional['pl']
  44.               )
  45.             );
  46.       });
  47.       </script>
  48.     <script type="text/javascript">
  49.          var icon = new google.maps.MarkerImage("http://maps.google.com/mapfiles/ms/micons/blue.png",
  50.          new google.maps.Size(32, 32), new google.maps.Point(0, 0),
  51.          new google.maps.Point(16, 32));
  52.          var center = null;
  53.          var map = null;
  54.          var currentPopup;
  55.          var bounds = new google.maps.LatLngBounds();
  56.          function addMarker(lat, lng, info) {
  57.          var pt = new google.maps.LatLng(lat, lng);
  58.          bounds.extend(pt);
  59.          var marker = new google.maps.Marker({
  60.          position: pt,
  61.          icon: icon,
  62.          map: map
  63.          });
  64.          var popup = new google.maps.InfoWindow({
  65.          content: info,
  66.          maxWidth: 300
  67.          });
  68.          google.maps.event.addListener(marker, "click", function() {
  69.          if (currentPopup != null) {
  70.          currentPopup.close();
  71.          currentPopup = null;
  72.          }
  73.          popup.open(map, marker);
  74.          currentPopup = popup;
  75.          });
  76.          google.maps.event.addListener(popup, "closeclick", function() {
  77.          map.panTo(center);
  78.          currentPopup = null;
  79.          });
  80.          }
  81.          function initMap() {
  82.          map = new google.maps.Map(document.getElementById("map"), {
  83.          center: new google.maps.LatLng(0, 0),
  84.          zoom: 14,
  85.          mapTypeId: google.maps.MapTypeId.ROADMAP,
  86.          mapTypeControl: false,
  87.          mapTypeControlOptions: {
  88.          style: google.maps.MapTypeControlStyle.HORIZONTAL_BAR
  89.          },
  90.          navigationControl: true,
  91.          navigationControlOptions: {
  92.          style: google.maps.NavigationControlStyle.SMALL
  93.          }
  94.          });
  95.          addMarker(18.17374500, 54.61604900,'<b></b><br/>1');
  96. addMarker(54.61604900, 18.17374500,'<b></b><br/>1');
  97.          center = bounds.getCenter();
  98.          map.fitBounds(bounds);
  99.  
  100.  }
  101.  
  102.   </script>
  103.   </head>
  104.  
  105. <div style="width:100%;height:100px;text-align:center">
  106.     <a href="index.php">Ostatnia pozycja</a><br/><br/>
  107.     <a href="index.php?i=last_day">Dzisiejszy dzień</a><br/><br/>
  108.    
  109.     <form action="index.php" method="get">
  110.         Wybrany dzień<input type="text" name="select_day" value="2016-04-02" id="datepicker">
  111.         <input type="submit" value="Pokaż">
  112.     </form>
  113.    
  114. </div>  
  115.    
  116.   <body onload="initMap()">
  117.     <div id="map" class="map" style="width:100%; height:100%"></div>
  118.   </body>
  119. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement