Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

Google maps marker changing depending on a marker in an xml file

30 views
Skip to first unread message

patsy_125

unread,
May 10, 2012, 4:02:32 AM5/10/12
to Google API Libraries for GWT
Hello i am trying to get markers to change icon and/or color
depending on a tag in an xml file, the coordinates and info of each
marker and it's type have been set in an xml file i am using this
Jquery function to fetch the info:
"
$.get(filename, function (xml) {
$(xml).find("marker").each(function () {
var name = $(this).find('name').text();
var address = $(this).find('address').text();
var image = $(this).find('Image').text();
var type = $(this).find('type').text();
"
i am rather new to jquery so could anyone help me write a function
that would check the type value and depending on what it finds the
marker.setIcon("") is a diffrent icon.
Hope it made sense.
Reply all
Reply to author
Forward
0 new messages