I have some view files at views/site/pages/XXX.php, and I would like all of them to use the same layout view that is located at views/layouts/page.php. But on the siteController.php, I modified the public function actions to be
public function actions()
{
return array(
// page action renders "static" pages stored under 'protected/views/site/pages'
// They can be accessed via: index.php?r=site/page&view=FileName
'page'=>array(
'class'=>'CViewAction',
'layout'=>'page.php'
),
);
}
But the page is now rendered as pure text. I have double checked the file name, it is correct.