I have a highCharts Pie Chart that when using the fiddle shows the tooltips on mouseOver for data points just fine, as well as the click events when I click on a LegendItem or the pop-out effect of pie slices, but when I plug my code into my site it doesn't work on any version of IE or google chrome. I don't know what the deal is. Here's the tooltips working, as well as the click events, but none of them work in my code.
$("document").ready(
function(){
$('#container').highcharts({
chart:{
type:'pie',
height: 250,
width: 350
},
colors:[
'#5485BC', '#AA8C30', '#5C9384', '#981A37', '#FCB319', '#86A033', '#614931', '#00526F', '#594266', '#cb6828', '#aaaaab', '#a89375'
],
title:{text: null},
plotOptions: {
pie: {
allowPointSelect: true,
cursor: 'pointer',
showInLegend: true,
dataLabels: {
enabled: false,
formatter: function() {
return this.percentage.toFixed(2) + '%';
}
},
}
},
legend: {
enabled: true,
layout: 'vertical',
align: 'right',
verticalAlign: 'middle'
},
series: [{
type: 'pie',
dataLabels: {
},
data: [
['Domestic Equity', 38.5],
['International Equity', 26.85],
['Other', 15.70],
['Cash and Equivalents', 10.48],
['Fixed Income', 8.48]
]
}]
});
});
A second question I had was if I could do a switch statement within the data, basically create a function that passes in 1 parameter and depending on the parameter value, change up my data[] values?
Thanks for your help, NickG