Echarts Series-Histogram (bar chart) Example one

Source: Internet
Author: User

Echarts Home: http://echarts.baidu.com/index.html

Echarts-2.1.8:http://echarts.baidu.com/build/echarts-2.1.8.zip

Echarts Official Example: http://echarts.baidu.com/doc/example.html

Echarts Official API Document: Http://echarts.baidu.com/doc/doc.html

Echarts Series-Histogram (bar chart) Example 11, project structure


js folder: After downloading the echarts, decompression, such as the root directory after decompression is echarts-2.1.8, then to Echarts-2.1.8\doc\example\www path, the inside of the JS folder directly copied and pasted into the project Webroot root directory

echarts.jsp: Create a new echarts.jsp under the Webroot root directory

echarts.jsp

<%@ page language= "java" import= "java.util.*" pageencoding= "UTF-8"%><%string path = Request.getcontextpath () ; String basepath = request.getscheme () + "://" +request.getservername () + ":" +request.getserverport () +path+ "/";%> <! DOCTYPE HTML PUBLIC "-//w3c//dtd HTML 4.01 transitional//en" >


After completing the above steps, the project is published to the server, the browser access to echarts.jsp (because this instance has not yet interacted with the background, just first to do a foreground usage introduction, so you can change the echart.jsp directly into echarts.html file, Put it with the JS folder in the same level directory, and then directly open echarts.html with the browser, you can see the following effect



There is a toolbox in the upper right corner of the picture, click the "Line chart Toggle" button, the effect is as follows



More chart style settings to view Echarts's official API documentation


Echarts Series-Histogram (bar chart) Example one

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.