Hi All,
I am new to Yii framework, here is this basic but still confusing problem. Following is my code snippet.
In my controller script:
public function actionHelloWorld()
{
$this->render('helloWorld',array('var'=>'this is me'));
}
In the corresponding view:
<h1>Hello, World!</h1>
<h3><?php echo $var; ?></h3>
However, in the output, only <h1> gets printed out, looks like $var is unaccessible in the view. Any suggestion? Many thanks in advance!