So the title says it all i want to be able to display an iframe for the you tube video that he has stored in the inside of the database i am doing the following and it is giving
array(
'header'=>'Video',
'name'=>'videoUrl',
'value'=>'<iframe width="560" height="315" src="<?php echo $model->videoUrl ?>" frameborder="0" allowfullscreen></iframe>',
'type'=>'html',
),
As type i have tried eveything like raw,html and text but it still gives me an error like this all the time.
Parse error: syntax error, unexpected '<' in C:\Users\Steve\Documents\Drive\Frameworks\yii\framework\base\CComponent.php(612) : eval()'d code on line 1
You need to change it like below:
As everything in
value
will be passed into PHP'seval()
function.