PHP and FusionCharts create interactive Drilling Reports

Source: Internet
Author: User

When data is analyzed, charts are directly displayed, and fake tables can interact with each other, which improves the performance. This article describes how to use php with the open-source report library FusionCharts (Project address: www.fusioncharts.com/) to create interactive Drilling Reports. A drilling report refers to a new report that can be opened when a user clicks the data axis in the report. This facilitates navigation between different reports.

  Introduction to link charts

Generally, the data in a common chart is independent. How can we aggregate the data and navigate between these charts? This is exactly what mongocharts can achieve. It is a new drilling feature added in FusionCharts 3.2. It allows you to create unlimited drill-through charts with only one data source. All links are from the parent chart and its data.

In this article, we will learn how to combine charts with web applications. The Mysql database contains the required data, while the PHP program extracts the data from the database, and FusionCharts processes and displays the data. Their relationships are as follows:

If you want to learn more about structured charts, you can read the following Article introduction (http://kb.fusioncharts.com/questions/459/What+is+a+Drill-down+chart ?), The main points of this article are summarized as follows:

1. the drill-down report uses the default settings of the parent chart to display data;

2. The drilling layer of each layer can be set additionally. Of course, you can change the setting and chart type of each drilling layer;

3. You can open a linked chart in a new window, including the jQuery dialog box, lightbox, extJS window, and more;

4. Support using Javascript to expand events.

  What should we do?

We often need to monitor the number of visitors to our website applications and see if they have grown. In this article, we will make a small application, it shows the number of registered users on our website over a period of time.

  Preparation:A web server that supports php. Here we use apache and mysql databases to download FusionCharts.

  Step 1. Initial settings

Create an empty database fctutorial and create a subdirectory of fcdemo to store PHP files.

  Step 2 initialize database data

Here we create a users table. Here there are only two simple fields: ID and user registration time:

Related Article

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.