Sorry for my no ideal English!
In need change url from ‘ad?region=dp&city=zp’ to ad/dp/zp.
I know, that I can do this with UrlManager. But I have a problem with a GET form-filter: I can not paste to form action createUrl $params from this form field.
My form:
$form=$this->beginWidget('CActiveForm', array(
'method'=>'get',
'action'=>Yii::app()->createUrl('ad', array('region'=> here I need paste value from region, 'city' => here I need paste value from city)),
));
echo $form->dropDownList($region,'name', $regions, array(
'name' => 'region',
'options' => array($_GET['region']=>array('selected'=>true)),
));
echo $form->dropDownList($city,'name', $cities, array(
'name' => 'city',
'options' => array($_GET['city']=>array('selected'=>true)),
));
$this->endWidget();
How I can do this? And Do I correctly understand the logic of form-filter?
Thank You!