login.php as index

good day everyone… i am a newbie to yii framework… i already created my application… but my problem now is that when i changed my index to login, i got an error "Undefined variable: model"…

please help… thanks…

p.s.

if i am in not the right thread, please tell me where to transfer my query… thanks…

Please, explain what you wanna do in a clear way.

go to "config/main.php" and set default controller


return array(

    ...

    'name'=>'My Yii App',

    'defaultController'=>'site',

    ....



and ater that ind your SiteController (or which controller holds your login.php) and add


class SiteController extends Controller

{

    var $defaultAction = 'login';

...

}

this one will set your application first action as --> site/login -> views/site/login.php

narkomanC Thanks