yii 1 print attributes of model code example Example: yii2 print model header('Content-type: text/plain'); print_r($var); exit;