highstock Highstock widget

  1. Requirements
  2. Usage
  3. Resources

Highstock lets you create stock or general timeline charts in pure JavaScript, including sophisticated navigation options like a small navigator series, preset date ranges, date picker, scrolling and panning.

Requirements

  • Yii 1.0 or above
  • PHP 5.1 or above

Usage

To use this widget, you may insert the following code in a view:

$this->Widget('ext.highstock.HighstockWidget', array(
  'options'=>array(
    'theme'=>'grid',
    'rangeSelector'=>array('selected'=>1),
    'title'=>array('text'=>'USD to EUR exchange rate'),
    'xAxis'=>array('maxZoom'=>14 * 24 * 3600000 ),
    'yAxis'=>array('title'=>array('text'=>'Exchange rate')),
    'series'=>array(array('name'=>'USD to EUR','data'=>'js:usdeur')),
  )));
Yii::app()->clientscript->registerScript('highstock',"
var usdeur = [
[Date.UTC(2003,8,24),0.8709],
[Date.UTC(2003,8,25),0.872],
[Date.UTC(2003,8,26),0.8714],
[Date.UTC(2011,4,10),0.6945]
];
",CClientScript::POS_HEAD);

Resources

5 0
10 followers
1 218 downloads
Yii Version: 1.1
License: (not set)
Category: User Interface
Developed by: nk913
Created on: Oct 5, 2011
Last updated: 6 years ago

Downloads

show all

Related Extensions