index c6a8918c09b25089f228bfb8b41a0d0e168e96b9..0d6b5e2a7be98a16479033a6d9e298c97dba7ccd 100644 (file)
show_breadcrump (cfg, inst);
if (data->graph_count < MAX_SHOW_GRAPHS)
- {
printf ("<div class=\"graph-img\"><img src=\"%s?action=graph;%s%s\" "
"title=\"%s / %s\" /></div>\n",
script_name (), params, time_params, title, descr);
- printf ("<div style=\"clear: both;\"><a href=\"%s?action=graph_data_json;%s%s\">"
- "Get graph data as JSON</a></div>\n",
- script_name (), params, time_params);
- }
else
printf ("<a href=\"%s?action=show_instance;%s\">Show graph "
""%s / %s"</a>\n",
script_name (), params, title, descr);
+ printf ("<div id=\"c4-graph%i\" class=\"graph-json\"></div>\n", data->graph_count);
+ printf ("<script type=\"text/javascript\">c4.graphs[%i] = { \"params\": \"%s\", \"begin\": %li, \"end\": %li };</script>\n",
+ data->graph_count, params, (long) begin, (long) end);
+
+ printf ("<div style=\"clear: both;\"><a href=\"%s?action=graph_data_json;%s%s\">"
+ "Get graph data as JSON</a></div>\n",
+ script_name (), params, time_params);
+
data->graph_count++;
return (0);