rgraph Wrapper for RGraph charts library

  1. Requirements
  2. Usage
  3. Resources

RGraph is a charts library that uses Javascript and HTML5 to draw and supports over twenty different types of charts. Using the new HTML5 canvas tag, RGraph creates these charts inside the web browser, meaning quicker pages and less web server load. This leads to smaller page sizes and faster websites.

Requirements

  • RGraph
  • YiiFramework 1.1.x (Tested on 1.1.10)

Usage

Download RGraph library and decompress it to protected/vendors/rgraph (you can change this path with the rGraphPath parameter)

Download this extension wherever you want (in this example, we'll use protected/widgets)

$this->widget('application.widgets.rgraph.RGraphBar', array(
	'data' => array(1, 3, 5, 7, 2, 4, 6, 10, 8, 9, 12, 11),
	'options' => array(
		'chart' => array(
			'gutter' => array(
				'left' => 35,
			),
			'colors' => array('red'),
			'title' => 'A basic chart',
			'labels' => array(
				'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'
			),
		)
	)
));

Resources

5 0
11 followers
1 558 downloads
Yii Version: 1.1
License: BSD-2-Clause
Category: User Interface
Developed by: robregonm
Created on: Apr 25, 2012
Last updated: 11 years ago

Downloads

show all

Related Extensions