I have a MySql database with a table which has several columns, including the date and time. The rest are columns of values such as temperature.
I just need to make a line graph with the date / time combined on the horizontal axis and the values on the vertical.
<script>
var chart = AmCharts.makeChart( "chartdiv", {
"type": "serial",
"dataLoader": {
"url": "data.php"
},
"graphs": [ {
"valueField": "temperatura",
"bullet": "round",
"bulletBorderColor": "#FFFFFF",
"bulletBorderThickness": 2,
"lineThickness ": 2,
"lineAlpha": 0.5
} ],"pathToImages": "http://www.amcharts.com/lib/images/",
"categoryField": "fecha",
"dataDateFormat": "YYYY-MM-DD",
"startDuration": 1,
"rotate": true,
"categoryAxis": {
"parseDates": true
}
} );
"dataUpdated" event
</script>
What I am achieving is popular the graph with data but the axes remain inverted (vertical for date). I am using only the date, then I would have to add the time too.
Million thanks to the one who can help me