Hi, I’d also like to know how to update a plot dinamically via Ajax.
I have something like this:
<?php
$this->widget('application.extensions.EFlot.EFlotGraphWidget',
array(
'data'=>array(
array(
'label'=> 'line',
'data'=>array(
array(1,1),
array(2,7),
array(3,12),
array(4,32),
array(5,62),
array(6,89),
),
'lines'=>array('show'=>true),
'points'=>array('show'=>true),
),
array(
'label'=> 'bars',
'data'=>array(
array(1,12),
array(2,16),
array(3,89),
array(4,44),
array(5,38),
),
'bars'=>array('show'=>true),
),
),
'options'=>array(
'legend'=>array(
'position'=>'nw',
'show'=>true,
'margin'=>10,
'backgroundOpacity'=> 0.5
),
),
'htmlOptions'=>array(
'style'=>'width:400px;height:400px;'
)
)
);
?>
<?php
echo CHtml::ajaxSubmitButton(
'Prova',
array('reqFlot'),
array(
'update'=>'#<img src='http://www.yiiframework.com/forum/public/style_emoticons/default/huh.gif' class='bbc_emoticon' alt='???' />?',
)
);
?>
I don’t know how to handle the request.
Anyone?
Thanks