b03tz / StoreLocator

StoreLocator is a MODX addon that let's your customers search for stores in their vicinity.
http://www.scherpontwikkeling.nl
6 stars 10 forks source link

Custom Marker Images based on an attribute of each marker when parsed as XML #22

Open lingokid opened 10 years ago

lingokid commented 10 years ago

I have been trying everything I can to figure out how I can use several different marker images, each would be used based on the match to an attribute in the marker attributes being passed via xml.

I have several store types, each marker in my locations.xml document has an attribute of type. I have tried setting that attribute to a number or string and have not been able to use any type of logic in the jquery.storelocator.js file to assign the custom icons based on the value of the attribute.

I have tried conditional logic based on the attribute value, if statements, if/else statements, case statements and have not been able to get this working.

Any advice would be greatly appreciated.