FusionCharts Free: http://www.fusioncharts.com/goodies/fusioncharts-free/
Next, introduce js in the jsp page.
Copy codeThe Code is as follows: <script type = "text/javascript" src = "FusionChartsFree/JSClass/FusionCharts. js"> </script>
Then writeCopy codeThe Code is as follows: <script type = "text/javascript">
Var chart = new FusionCharts ("FusionChartsFree/Charts/FCF_Column3D.swf", "column1", "800", "600 ");
Chart. setDataURL ("FusionChartsFree/Gallery/Data/Column3D. xml ");
Chart. render ("div1 ");
</Script>
The parameters in the second line are as follows: the SWF address of the image to be displayed, the id of the image (which can be arbitrarily started, but is unique when multiple images exist on a page), the width of the image, the height of the image;
The third line is to set the XML address for data display;
The fourth line is the id of the DIV as the rendering image parameter;
Appendix:
Copy codeThe Code is as follows: <% @ page language = "java" import = "java. util. *" pageEncoding = "GBK" %>
<%
String path = request. getContextPath ();
String basePath = request. getScheme () + ": //" + request. getServerName () + ":" + request. getServerPort () + path + "/";
%>
<! Doctype html public "-// W3C // dtd html 4.01 Transitional // EN">
<Html>
<Head>
<Base href = "<% = basePath %>">
<Title> Demo </title>
<Script type = "text/javascript" src = "FusionChartsFree/JSClass/FusionCharts. js"> </script>
</Head>
<Body>
<Div id = "div1"> </div>
<Script type = "text/javascript">
Var chart = new FusionCharts ("FusionChartsFree/Charts/FCF_Column3D.swf", "column1", "800", "600 ");
Chart. setDataURL ("FusionChartsFree/Gallery/Data/Column3D. xml ");
Chart. render ("div1 ");
</Script>
</Body>
</Html>
Display Effect: