How to insert Timestamp Data when using dojox.charting.Chart2D
I am using dojox.charting.Chart2D to display Graphs/ Charts in our Application .
My Timestamp data would be in this format 2005-06-29 08:05:00 .
I am using dojox.charting.Chart2D to display Charts .
Could anybody please let me know how to insert this TimeStamp Data into the addSeries Method of Chart2D ??
Or please let me know what is the appropiate way 开发者_JAVA技巧for inserting Timestamp Data into DOJO Charts ??
help me , my work has been struck .
I would do this on the server side following Dojox's addSeries method. I would assume you are wanting to plot an array of timestamps, otherwise there would be only one point on the chart. You could do something like this:
chart1.addSeries(
"Series 1",
[
// Your server code here
// series is an array of times
foreach($series as $v) {
echo date("Y-m-d : H:i:s", $v).", ";
}
// End server code
]
);
精彩评论