Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7447369
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T12:35:16+00:00 2026-05-29T12:35:16+00:00

Goal: Get the TEXT address and then display the street view and map view

  • 0

Goal: Get the TEXT address and then display the street view and map view at the same time

Ref Site:

http://code.google.com/apis/maps/documentation/javascript/examples/streetview-simple.html

My site:
http://www.iamvishal.com/dev/property/P2154 (pls click the map view to see the map)

Problem: I am able to display the map and the address correctly but instreet view does not change. Any idea why ?

My js variable address hold the text address in this case “323235 Balmoral Terrace Heaton Newcastle Upon Tyne”

function initialize() 
{
var fenway = new google.maps.LatLng(42.345573,-71.098326);
var mapOptions = {
    center: fenway,
    zoom: 14,
    mapTypeId: google.maps.MapTypeId.ROADMAP
};

var map = new google.maps.Map(
document.getElementById("map_canvas"), mapOptions);

var panoramaOptions = {
    position: fenway,
    pov: {
         heading: 34,
         pitch: 10,
         zoom: 1
         }
   };

var panorama = new  google.maps.StreetViewPanorama(document.getElementById("pano"), 
panoramaOptions);

map.setStreetView(panorama);

var geocoderTwo = new google.maps.Geocoder();

geocoderTwo.geocode({"address":address},function(results, status)
{
   if (status == google.maps.GeocoderStatus.OK) 
   {
      map.setCenter(results[0].geometry.location);
      var marker = new google.maps.Marker
      ({
        map: map,
        position: results[0].geometry.location
      });
   }
else
{
  alert("Geocode was not successful for the following reason: " + status);
}
}


);


}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T12:35:17+00:00Added an answer on May 29, 2026 at 12:35 pm

    Here’s how I’ve created a streetview before:

    function createStreetMap(strMapCanvasID, yourLatLng)
    {
        var panorama;
    
        //once the document is loaded, see if google has a streetview image within 50 meters of the given location, and load that panorama
        var sv = new google.maps.StreetViewService();
    
        sv.getPanoramaByLocation(yourLatLng, 50, function(data, status) {
            if (status == 'OK') {
                //google has a streetview image for this location, so attach it to the streetview div
                var panoramaOptions = {
                    pano: data.location.pano,
                    addressControl: false,
                    navigationControl: true,
                    navigationControlOptions: {
                        style: google.maps.NavigationControlStyle.SMALL
                    }
                }; 
                var panorama = new google.maps.StreetViewPanorama(document.getElementById(strMapCanvasID), panoramaOptions);
    
    
                // lets try and hide the pegman control from the normal map, if we're displaying a seperate streetview map
                objCreatedMap.setOptions({
                    streetViewControl: false
                });
            }
            else{
                //no google streetview image for this location, so hide the streetview div
                $('#' + strMapCanvasID).parent().hide();
            }
        });
    }
    

    Update: and you could call this function directly from within your existing code (I’ve amended the function to use a LatLng rather than individual latitude and longitude values:

    if (status == google.maps.GeocoderStatus.OK) 
       {
          map.setCenter(results[0].geometry.location);
          var marker = new google.maps.Marker
          ({
            map: map,
            position: results[0].geometry.location
          });
    
          createStreetMap('yourStreetViewDiv', results[0].geometry.location);
       }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Goal: I want to get the text from the selected element and then create
Goal : Get a screenshot of a map with overlays(MKOverlayView) as well as the
My goal is to get a Time instance from a DateTime instance This has
My goal is to get various SEO-relevant information for various sites. Basically all the
How do i do that? Actually my main goal is to get which checkbox
Goal My goal is to to get Twitter Bootstrap to worth with my Play
The goal is to let users login via Twitter, get OAuth token and secret
My end goal is to get Erlang syntax highlighting in QsciScintilla using PyQt4 and
I am creating a Drupal 7 module. Currently my goal is to get the
So a webpage displays a long amount of text in paragraph format. The goal

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.