CLinkColumn imageUrl

Hi all,

I am using CLinkColumn to display a LinkedIn logo in one of my grids but I would like any advice on how to show this logo conditionally only if the users LinkedIn url is in the data base. The code right now looks like this:



	'header'=> 'LinkedIn',

	'imageUrl' => XHtml::imageUrl('linkedin.jpg'),





This will display the image on for every entry but will only activate the link for those entries that contain the linkedin url. This works right now but I believe it would look cleaner if only the correct images were displayed.


something like this, you may want to double check the syntax (i haven’t tried out the syntax yet):


'imageUrl' => '($data->linkedin_flag)?XHtml::imageUrl("linkedin.jpg"):false',