CActiveForm across controllers

Hello,

i can use CActiveForm with the corresponding model to handle form validation and submission.

However, the view needs a model variable to handle the input but this variable is specific to a particular controller & action. But if i want to display a form on every page, say login form or newsletter form how do i pass the model variable, except placing it in every action ?

best regards & thank you

hello, try to use a CAction class

If you want to display a view on every page like in your examples a login form the best way to achive this in yii is to create a widget for it which you can place for example in the layout.php file.

The wiki How to create nice modal login widget with CJuiDialog could be helpful