문제

I have a sample fusion table map here http://jsfiddle.net/qEGpz/
I want to set the marker to red_stars based on temperature >75 degree. But my code doesn't work correctly. Link to my fusion table is here https://www.google.com/fusiontables/DataSource?snapid=S567077W7iF Anyone please help. Thank you in advance.

With regards,
Pradeep Shankar M

도움이 되었습니까?

해결책

Your example seems to be working fine. What is the problem? Note: the red_stars icon is fairly subtle. Looks like a standard Google Maps red marker with a black center star vs. black center circle.

Here's the list of the allowed Fusion Table iconNames. Choose Visualize -> Map to see what they look like. Perhaps you need to use "capital_small_highlight".

Took another look and another guess as what your problem is. Try this:

layer8 = new google.maps.FusionTablesLayer({
    query: {
      select: 'Geometry',
      from: '4080901',
      where: "Temp >= 75"
    },
    styles: [ {
      where: "Temp >= '75'",
      markerOptions: {
        iconName: "red_stars",
      }
    }]
  });
  layer8.setMap(map);
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top