> I have searched for hours and tried all sorts of code and each time
> the map comes up blank when I try to make polylines show/hide at the
> same time as markers by category from a .xml file. At the moment I
> have polylines for Ferry Routes showing all the time and you can show/
> hide the markers for the stops.  Can someone please help me to make
> them show/hide together.http://www.australiantravel.info/boat.html

At the moment, your XML parsing routine reads an attribute called
'category' for each of your marker data, and when creating the actual
GMarker assigns a custom property .mycategory.   A reference to every
marker is held in a global array.  When things are clicked, your show/
hide routines scan through markers in the array and
examine .mycategory to determine whether to show or hide each marker.

So, one approach is to simply replicate that for your GPolylines.  Add
a category attribute to your XML. Parse it and attach it to your
GPolyline.  Keep a reference to every polyline in an array.  Scan the
array when required and show/hide as appropriate.
-- 
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