How To Display Image(Assets Folder)

Hello yii developers :o

I’m intrested to know how to display an image in the view file when it belongs in


I did try this code:

<?php echo CHtml::image(Yii::app()->request->baseUrl./'assets/85jru58d/images/image.png'/, 'image'); ?>

and it works :),

however I wanted to know how to avoid typing this part of the code:



when you ‘publish’ an asset (call Yii::app()->assetManager->publish(…)) you get the url to the published copy.