Cleaning up your page source to be something close to valid HTML can't hurt,
and it may well help.
But you also have plain old JavaScript errors. Don't you get this message
when you load the page with Firebug?
GPolygon.FromEncoded is not a constructor
The code it references is:
var poly = new GPolygon.FromEncoded({
...
});
As is often the case, the error message is just a bit misleading but it does
point you to the error.
The problem is not that GPolygon.FromEncoded "is not a constructor", the
problem is that GPolygon.FromEncoded does not exist. Look closely at the
docs:
http://code.google.com/apis/maps/documentation/javascript/v2/reference.html#GPolygon
Do you see why GPolygon.FromEncoded() doesn't work? (Hint: JavaScript is
case dependent.)
Also, you can take out the "new". It isn't needed here but isn't hurting
anything (except to give a slightly less informative error message that
you'd get without it).
-Mike
On Fri, Jul 23, 2010 at 8:29 AM, Rossko <[email protected]> wrote:
> > Are you saying if I moved my map off this page it may work?
>
> I've no idea, but for example there is more than one <body> tag and
> only one has your onload event attached. Whether it gets triggered or
> not will be browser dependant. There's little point in looking into
> problems in a known unpredictable environment.
>
> If you want to insert a "complete" webpage inside of another webpage
> content, use an <iframe>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Maps API" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-maps-api%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-maps-api?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-maps-api?hl=en.