<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
<script language="javascript" type="text/javascript" src="http://www.prioritymarketers.com/jqplot/src/jquery.jqplot.js"></script>
<script language="javascript" type="text/javascript" src="http://www.prioritymarketers.com/jqplot/src/plugins/jqplot.barRenderer.js"></script>
<script language="javascript" type="text/javascript" src="http://www.prioritymarketers.com/jqplot/src/plugins/jqplot.categoryAxisRenderer.js"></script>
<script language="javascript" type="text/javascript" src="http://www.prioritymarketers.com/jqplot/src/plugins/jqplot.pointLabels.js"></script>
<link rel="stylesheet" type="text/css" href="http://www.prioritymarketers.com/jqplot/src/jquery.jqplot.css">
<script type="text/javascript">
function drawChart() {
var s1 = [2, 6, 7];
var s2 = [7, 5, 3];
var s3 = [2, 3, 5];
var s4 = [1, 7, 2];
// chart data
var dataArray = [s1, s2, s3, s4];
// x-axis ticks
var ticks = ['Jan', 'Feb', 'Mar'];
// chart rendering options
var options = {
seriesDefaults: {
renderer:$.jqplot.BarRenderer
},
axes: {
xaxis: {
renderer: $.jqplot.CategoryAxisRenderer,
ticks: ticks
}
}
};
// draw the chart
$.jqplot('chartDivId', dataArray, options);
}
</script>
</head>
<body onload='drawChart()'>
<div id="chartDivId" style="margin-top:20px; margin-left:20px; width:400px; height:300px;"></div>
</tr>
</body>
</html>
这是上述程序成功运行的 jsfiddle( http://jsfiddle.net/JWhmQ/2023/ )。但它在 Eclipse 上运行时不显示任何 js 图。
即使我包含了 js 文件,它仍然没有显示任何情节
请给我一些解决方案..