Google Answers Logo
View Question
 
Q: Little Help with Google Maps Code... ( No Answer,   0 Comments )
Question  
Subject: Little Help with Google Maps Code...
Category: Computers > Programming
Asked by: cdn2005-ga
List Price: $3.00
Posted: 01 Apr 2006 16:06 PST
Expires: 03 Apr 2006 17:41 PDT
Question ID: 714437
Please give me the exact HTML to have this code provide the pop-up
window when the page loads instead of when clicked on - can't figure
it out.

//<![CDATA[

    if (GBrowserIsCompatible()) {

      function createMarker(point,html) {
        // FF 1.5 fix
        html = '<div style="white-space:nowrap;">' + html + '</div>';
        var marker = new GMarker(point);
        GEvent.addListener(marker, "click", function() {
          marker.openInfoWindowHtml(html);
        });
        return marker;
      }

      var map = new GMap(document.getElementById("map"));
      map.addControl(new GLargeMapControl());
      map.addControl(new GMapTypeControl());
      map.centerAndZoom(new GPoint(-79.359741, 43.907787), 8);
    
      var point = new GPoint(-79.90138, 43.65654);
      var marker = createMarker(point,'Testing 1234')
      map.addOverlay(marker);

      

    }

    
    else {
      alert("Sorry, the Google Maps API is not compatible with this browser");
    }

    

    //]]>
Answer  
There is no answer at this time.

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy