Hi all,
I want to display an icon with a link only on rows having a satisfied condition.
With the code below, each row has the icon with a good link when condition is satisfied or partial link if not
good link : http://localhost/grocerycrud/index.php/main/detail_circuit?id_circuit=1
partial link : http://localhost/grocerycrud/index.php/main/circuits
$crud->add_action('Profil', '', '','profil-icon',array($this,'_profil_callback'));
function _profil_callback($value, $row)
{
if ($row->lien=='')
{
return '';
}
else
{
return site_url('main/detail_circuit').'?id_circuit='.$row->id_circuit;
}
}
Thanks in advance for your help