codice:
function drawTable(contenuto) {
var data = new google.visualization.DataTable();
data.addColumn('string', 'Name');
data.addColumn('number', 'Salary');
data.addColumn('boolean', 'Full Time');
data.addRows(5);
data.setCell(0, 0, 'John');
data.setCell(0, 1, 10000, '$10,000');
data.setCell(0, 2, true);
data.setCell(1, 0, 'Mary');
data.setCell(1, 1, 25000, '$25,000');
data.setCell(1, 2, true);
data.setCell(2, 0, 'Steve');
data.setCell(2, 1, 8000, '$8,000');
data.setCell(2, 2, false);
data.setCell(3, 0, 'Ellen');
data.setCell(3, 1, 20000, '$20,000');
data.setCell(3, 2, true);
data.setCell(4, 0, 'Mike');
data.setCell(4, 1, 12000, '$12,000');
data.setCell(4, 2, false);
// !! FINO A QUI ARRIVO CON ALERT
var table2 = new google.visualization.Table(document.getElementById('table_div'));
// !! QUI NON ARRIVO CON ALERT
table2.draw(data, {showRowNumber: true});
google.visualization.events.addListener(table2, 'select', function() {
var row = table2.getSelection()[0].row;
alert('You selected ' + data.getValue(row, 0));
});
}
// Questa parte è mia
</script>
<body>
<div id="teble_div" style="width: Auto; height: 900px;"></div>
<div id="newgraphic3" style="min-height: 400px !important;"></div>
<div id="container3" style="overflow: auto; height: Auto; margin: 0 auto"></div>
</body>
Vedete per favore cosa c'è che non va nel codice e magari se sfugge qualcosa. Grazie