Open Site When Click On Image

hi all

  i am new to yii.

in my application , i want to add link to image in that whene we click on image then linked site will open in new tab .

please reply me

thnks in advance


// Hi Jalpa Patel You may try this one. it will work


   $image = CHtml::image(Yii::app()->request->baseUrl.'/images/logo.png', 'alt txt', array('class'=>"img-preview",));

   echo CHtml::link($image, array('site/index'), array('target'=>'_blank'));