problem with opening big image on clck at thumbnail


I am trying to use following code in cGridView to display thumbs and open main image on clicking at thumb, but it seems like an impossible thing to achieve in YII, the problem is that i get big image url as index.php?=r=then imagepath. if i remove index.php?=r, images are displayed, else error is returned.

Here’s the code:




          'value'=> 'CHtml::link(CHtml::image(Yii::app()->baseUrl."/images/photogallery/".$data->gallery1->provider_id."/".$data->gallery."/thumb/".$data->image, "image", array("height"=> 70, "width"=>70)), array(Yii::app()->baseUrl . "/images/photogallery/".$data->provider_id."/" . $data->gallery."/" .$data->image)), array("target"=>"_blank"))',

Please suggest me a way to do this!