CController and Controller

Hi,

I’ve just started to learn Yii and follow “Where to Start with Yii” tutorial and got stuck on CController.

when i run code:

class MessageController extends CController

{

public function actionIndex()


{


    $this->render('index');


}

)

It’s show exception:

CException

Description

Property "MessageController.breadcrumbs" is not defined.

Source File

C:\DevEnv\wamp\www\lab\protected\views\message\index.php(2)

But when i change the "extends CController" to "extends Controller"

it was successfully show the proper page.

Please help …

thanksss

The breadcrumbs property is defined in the customized base class Controller, which is located in your application’s protected/components directory.

Thanks Qiang,

I understand now that Controller is a child of CController,

and actually MessageController can derive directly from CController with the same property definition as Controller.

Rgrds,