Download the PHP package jaxon-php/jaxon-flot without Composer
On this page you can find all versions of the php package jaxon-php/jaxon-flot. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package jaxon-flot
Javascript charts for Jaxon with Flot
Javascript charts for Jaxon with the Flot library. https://www.flotcharts.org
See the plugin in action with sample code.
- https://www.jaxon-php.org/examples/advanced/flot.html
- https://www.jaxon-php.org/examples/advanced/flot-types.html
- https://www.jaxon-php.org/examples/advanced/flot-axes.html
Installation
Install this package with Composer.
Draw graphs
Create a new card to be displayed in a div with a given id, eg. "flot-container".
Add a graph in the card, and set its parameters.
The options are defined in the API docs.
Multiple data series can be added to a graph.
Each series can be defined using an array of points.
Or a javascript loop expression. The loop goes from a start to an end value, with the specified step. The last parameter is a Javascript function defined in the app, which takes a point as parameter and returns the corresponding value.
The X axis and Y axis options can also be set. Multiple X axis and Y axis can be added. For each axis, the labels can be optionally set either with an array of points, or with a loop expression.
Set the dimensions of the card.
Finally, draw the graph.
You can add as many graphs as you need in a single card, and you can draw many cards in a single page.
Draw a pie
Drawing a pie chart requires the pie plugin for Flot to be loaded. Call this PHP code before loading the page, or add the Flot pie plugin manually.
Create a new card to be displayed in a div with a given id, eg. "flot-container".
Set the card options.
Add the pie to the card
Finally, draw the graph.
Only one pie can be added to a card.
Contribute
- Issue Tracker: github.com/jaxon-php/jaxon-flot/issues
- Source Code: github.com/jaxon-php/jaxon-flot
License
The project is licensed under the BSD license.