Reputation: 711
I am trying to load a pie chart in an ASP.NET webpage using the following URL: http://chart.apis.google.com/chart?cht=p3&chs=340x140&chdl=field1%7Cfield2%7Cfield3%7Cfield4&chl=100%%25%7C0%%25%7C0%%25%7C0%%25&chco=B32222|CC5C5C|BFBFBF|696969&chtt=&chts=000000,24&chd=t:100%,0%,0%,0%. However, it only shows the legend for the chart, and not the chart itself. As you can see from the URL, there are valid values being passed. Could anyone explain why this is happening?
This is the context in which the URL is being used:
google.maps.event.addListener(marker, "click", function () {
'<div id="chartDiv">' + //Pie chart image
'<img src="http://chart.apis.google.com/chart?cht=p3&chs=340x140&chdl=field1%7Cfield2%7Cfield3%7Cfield4&chl='
+ field1+
'%25%7C'
+ field2+
'%25%7C'
+ field3+
'%25%7C'
+ field4+
'%25&chco=B32222|CC5C5C|BFBFBF|696969&chtt=&chts=000000,24&chd=t:'
+ field1+ ',' + field2+ ',' + field3 + ',' + field4 +
'" />' +
'</div>' + // End of chartdiv
}
Upvotes: 1
Views: 68
Reputation: 61275
Couple things to get the chart to show...
Removed extra
%
's fromchl
Removed all%
's fromchd
Upvotes: 1