I want to call a css class in html link tag using cakephp, i.e
<li><a href="#"><i class="icon-trash"></i> Delete Account</a></li>
don’t know how to do this, I’ve tried much but every time its disturbing my css, displays the icon before or above the link name, what I supposed to be in cake is
<li> <?php echo $this->html->link('Delete Profile',
array('controller'=>'Users','action'=>'delete',$current_user['user_id']),
array('icon'=>'<i class="icon-trash">'.'</i>'),array('escape'=>false));?></li>
I am using cakephp 2.2.5 and xamp 1.7.7.
thanks in advance.
Your
Html::link()is not correct. There is noiconparam, and you have an extra array.Use this: