Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div class="container-fluid">
- <div class="row" style="margin-top: 10px">
- <div class="col-md-6 col-xs-6">
- <div class="well">
- <h4>Settings</h4>
- <div id="panomap"></div>
- <h5 class="text-center">Click on the map or type in the co-ordinates.</h5>
- <div class="row">
- <div class="col-md-12 col-xs-12">
- <div id="map">
- </div>
- //... others items...
- //--JavaScript part
- var position = {lat: 40.72815832561118, lng: -73.99564975565187};
- sv = new google.maps.StreetViewService();
- var polylineOptionsActual = new google.maps.Polyline({
- strokeColor: '#FF0000',
- strokeOpacity: 1.0,
- strokeWeight: 10
- });
- directionsService = new google.maps.DirectionsService();
- directionsDisplay = new google.maps.DirectionsRenderer({polylineOptions: polylineOptionsActual});
- // Setup up the map
- map = new google.maps.Map(document.getElementById('map'), {
- center: position,
- zoom: 17,
- mapTypeControl: false,
- mapTypeId: google.maps.MapTypeId.ROADMAP,
- streetViewControl: false,
- mapTypeControlOptions: {
- style: google.maps.MapTypeControlStyle.HORIZONTAL_BAR},
- navigationControl: true,
- navigationControlOptions: {
- style: google.maps.NavigationControlStyle.SMALL
- }
- });
- map.setOptions({styles: MyOwnStyle});
- //console.info('pre GDireccion....');
- //console.info(directionsService);
- // Create a marker on click, if the position has Street View data.
- map.addListener('click', function(event) {
- sv.getPanorama({location: event.latLng, radius: 50},
- updateLocationByClick);
- });
- panorama = new google.maps.StreetViewPanorama(
- document.getElementById('panomap'), {
- position: {lat: 40.72815, lng: -73.99564},
- pov: { heading: 270, pitch: 0 },
- visible: true,
- linksControl: true
- });
- //...
Add Comment
Please, Sign In to add comment