I've recreated what I removed and have got to the same place I did
before...
At the moment the page only displays the markers - no polygons.
When a marker is clicked I get a JS error saying "marker.polygons is
null or not an object."

So, I then change the line:
var marker = new GMarker(point, customIcons[Year]);
to read
var marker = new GMarker(polygons, point, customIcons[Year]);

This stops the markers appearing at all, giving the JS error " 'x' is
null or not an object "

This is where I get stuck..!

-Andrew


On 27 Oct, 12:04, Marcelo <[email protected]> wrote:
> On Oct 27, 10:11 am, Andyroo1000 <[email protected]>
> wrote:
>
> > When you view the page map.php it creates a session with year, easting
> > and northing data in it.
> > Again, this is tested an working correctly...
>
> Aha!
> ... and do you know why I couldn't see the markers?
> Because I don't accept cookies, so the session information wasn't
> saved.
>
> So, it is tested and working correctly **IF** the visitor accepts
> cookies. :-)
>
> Now, back to your original question, I see that you *STILL* have made
> no attempt at implementing what I suggested in my first post on this
> thread.
> Would you like to give it a try?
>
> --
> Marcelo -http://maps.forum.nu
> --
>
>
>
>
>
> > -Andrew
>
> > On 26 Oct, 14:04, Marcelo <[email protected]> wrote:
>
> > > On Oct 26, 2:37 pm, Andyroo1000 <[email protected]>
> > > wrote:
>
> > > > The map.php page passes coordinate and year info to the output-xml.php
>
> > > No, it doesn't. You are calling output-xml.php from the line:
> > >   GDownloadUrl("output-xml.php", function(data) { ...
> > > and there are no parameters in that request.
>
> > > --
> > > Marcelo -http://maps.forum.nu
> > > --
>
> > > > page which returns the formatted XML. Going straight to output-xml.php
> > > > will show an error in the MySQL query.
>
> > > > I tried to implement what you suggested but I think I must have been
> > > > putting it in the wrong place as the polygons stopped appearing,
> > > > leaving just the markers on the map.
> > > > I moved it round, got errors, moved it round some more, got just
> > > > markers and couldn't get it to show the polygons on marker clicks no
> > > > matter what I tried.
> > > > I took what I edited out so that it displayed both the markers and the
> > > > polygons and you can see what is being passed to the map.
>
> > > > Please have another look, let it churn away and you should see what I
> > > > mean.
>
> > > > Cheers,
> > > > -Andrew
>
> > > > On 26 Oct, 12:32, Marcelo <[email protected]> wrote:
>
> > > > > ... but I don't see any markers on that map, or any attempt at
> > > > > implementing what I suggested in my previous post.
>
> > > > > Start by fixing your PHP, so that you can get some markers on the 
> > > > > map:http://www.bluesky-world.com/dev_area/output-xml.php
>
> > > > > Then *try* to implement what I suggested earlier, and if you can't get
> > > > > it to work then post to the forum again.
>
> > > > > --
> > > > > Marcelo -http://maps.forum.nu
> > > > > --
>
> > > > > On Oct 26, 10:45 am, Andyroo1000 <[email protected]>
> > > > > wrote:
>
> > > > > > Of course, my apologies..!
>
> > > > > >http://tinyurl.com/yfjkqns
>
> > > > > > -Andrew
>
> > > > > > On 23 Oct, 11:20, Marcelo <[email protected]> wrote:
>
> > > > > > > On Oct 23, 12:10 pm, Andyroo1000 <[email protected]>
> > > > > > > wrote:
>
> > > > > > > > Suggestions welcome!!
>
> > > > > > > Suggestion:
> > > > > > > Please read and follow the group's posting 
> > > > > > > guidelines:http://groups.google.com/group/Google-Maps-API/web/suggested-posting-......
>
> > > > > > > --
> > > > > > > Marcelo -http://maps.forum.nu
> > > > > > > --
>
> > > > > > > > -Andrew
>
> > > > > > > > On 22 Oct, 18:45, Marcelo <[email protected]> wrote:
>
> > > > > > > > > On Oct 22, 6:14 pm, Andyroo1000 
> > > > > > > > > <[email protected]>
> > > > > > > > > wrote:
>
> > > > > > > > > > Does anyone know of any way of doing this?
>
> > > > > > > > > hmmm ...I wonder if anyone knows.
> > > > > > > > > You happen to be in a group dedicated to the Google Maps API, 
> > > > > > > > > so I'd
> > > > > > > > > put my money on a "yes" for an answer to that question. ;-)
>
> > > > > > > > > You could add the polygon to its marker as a property, and 
> > > > > > > > > then add a
> > > > > > > > > click event handler that opens the infoWindow, (not speech 
> > > > > > > > > bubble),
> > > > > > > > > and in that same event handler toggle the polygon with 
> > > > > > > > > something like
>
> > > > > > > > > if (marker.polygon.isHidden()) {}
> > > > > > > > >   marker.polygon.show();
> > > > > > > > >   marker.openIngoWindow(html);}
>
> > > > > > > > > else {
> > > > > > > > >   marker.polygon.hide();
> > > > > > > > >   map.closeInfoWindow();
>
> > > > > > > > > }
>
> > > > > > > > > Of course you'd need to pass the relevant content of the html 
> > > > > > > > > variable
> > > > > > > > > to the function that creates the marker and attaches the event
> > > > > > > > > listener.
>
> > > > > > > > > --
> > > > > > > > > Marcelo -http://maps.forum.nu
> > > > > > > > > --- Hide quoted text -
>
> > > > > > > - Show quoted text -- Hide quoted text -
>
> > > > > - Show quoted text -- Hide quoted text -
>
> > > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to