The complete code , including the database, css, scripts, etc is a bit to big to include.
I did include the relevant function is, which is called every hour.
Also the chart is drawn on a very simple jquery based Tab frame.
When the chart tab is selected this function is also called.
When this function is called I do see a complete redraw taking place on the tab, with exception of the two labels ‘Celsius’ and ‘Hour’ These two become more black with every call to the function.
function grid() {
if (typeof window.chart !== ‘undefined’ ) { window.chart.clearAll(); }
window.chart = new dhtmlXChart(
{
view: “line”,
padding:{
bottom:75
},
origin:0,
container: “chart1”,
value: “#data4#”,
tooltip: “#data4#”,
label: “”,
yAxis:{
start:0,
end:40,
step:5,
title:“Celsius”
},
xAxis:{
title: “Hour”,
template: “#data0#”
}
}
);
chart.addSeries(
{
line:{ color:"#B56AB5" },
value:"#data3#",
tooltip: “#data3#”
});
var mygrid = new dhtmlXGridObject("gridbox1"); //Container id for grid
mygrid.setImagePath("dhtmlx/codebase/imgs/"); //Path yo table images
mygrid.setHeader("Time,Date,Valid,Temp1,Temp2"); //Colom names
mygrid.setInitWidths("80,80,50,70,70"); //Table Colom width
mygrid.setColTypes("ro,ro,ro,ro,ro"); //Set coloms to READ ONLY
mygrid.setSkin("dhx_skyblue"); //Set skin
mygrid.init();
mygrid.loadXML("scripts/connector.php", function(){
chart.parse(mygrid,"dhtmlxgrid");
});
}