I know this question has been asked before and I have looked at other Stack Overflow examples and elsewhere but have been looking at this code for too long and I am stumped still.
In this fiddle, I have the markers for what will be two of many categories. I tried to set up a categories function displayMarkers
to filter and toggle on and off the markers for each category.
I cribbed from these examples with no luck.
When I try to call the displayMarkers
function and and pass a parameter (albacore218)
, I get ReferenceError: albacore218 is not defined
.
Data is in JSON and works just fine to populate the data in the marker infowindows. What I don't understand is why the JSON will work in the infowindow but when I try to access the data with the categories function I have no success.
Please let me know what I am missing or am not understanding. Thanks for your help.