Hey Guys
I have little problem when I pass the value one page to another. From page one, I have dropdown from different table and want to pass the value (start_date) to another page. here is my view file
page1 view file:
<tr>
<td><?php echo CHtml::activeLabel($form,'start_date'); ?></td>
<td><?php
$criteria = new CDbCriteria;
$criteria->order = 'start_date';
echo CHtml::activeDropDownList($form,'start_date',CHtml::listData(Test::model()->findAll($criteria),'id','start_date'), array('prompt'=>'Please select Start Date'));
?></td>
</tr>
page 1 controller
public function actionReport()
{
$form=new TestEx;
if(isset($_POST['TestEx']))
{
$form->attributes=$_POST['TestEx'];
if($form->validate())
{
$this->redirect(array('view','L_id'=>$form->L_id,'TestP_id'=>$form->TestP_id,'Test_i_id'=>$form->Test_i_id,'TestC_id'=>$form->TestC_id,'Start_date'=>$form->start_date));
}
}
$this->render('report',array('form'=>$form));
}