Google Groups Home
Help | Sign in
Message from discussion Error thrown from Google API
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Mila  
View profile
 More options Jun 17, 11:46 pm
From: Mila <maureenstr...@hotmail.com>
Date: Tue, 17 Jun 2008 11:46:27 -0700 (PDT)
Local: Tues, Jun 17 2008 11:46 pm
Subject: Re: Error thrown from Google API
Getting same problem as of yesterday.

Unfortunately can't post a link but the error is here in the eval of
the api code

S.prototype.ev=function(a){return new M(a.x+this.Ve.width,a.y
+this.Ve.height)};

Here is the function called.  Will do some try / catch blocks as well.

    function initialize()
    {
      map = new GMap2(document.getElementById("map_canvas"));
      map.setCenter(new GLatLng(34, 0), 15);
      geocoder = new GClientGeocoder();
      document.forms[0].q.value = QueryString("postalCode");
      showLocation();
    }

    function addAddressToMap(response)
    {
      map.clearOverlays();
      if (!response || response.Status.code != 200)
      {
        alert("Sorry, we were unable to find that address");
      }
      else
      {
        place = response.Placemark[0];
        point = new GLatLng(place.Point.coordinates[1],
place.Point.coordinates[0]);
        map.addControl(new GLargeMapControl());
        var mapControl = new GMapTypeControl();
        map.addControl(mapControl);
        map.addControl(new GScaleControl());
        map.addControl(new GOverviewMapControl());
        geocoder.getLatLng(     document.forms[0].q.value,
function(point) {      if (!point)
{        alert(document.forms[0].q.value + " not found");      } else
{        map.setCenter(point, 15);        var marker = new
GMarker(point);        map.addOverlay(marker);      }    }  );
      }
    }

Sorry, not too pretty on cut and paste.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google