hi i am trying to run two functions on single onclick. here is me code.
echo $this->Html->link('<span class="image"><i class="ico ico-logout"></i></span><span>' . __('Sign Out5') . '</span>', array('controller' =>'users', 'action' => 'logout', 'admin' => false), array('escape' => false, 'onclick' => 'signOut()','onClick' => 'onClickStr()' ));
look at this...
array('escape' => false, 'onclick' => 'signOut()','onClick' => 'onClickStr()' )..
i tried like
array('escape' => false, 'onclick' => 'signOut()', 'onClickStr()' )
but not worked.
i tried on many way still not get any results.
You can't have duplicate keys in an array. Put both function call separated by ;
.
array('escape' => false, 'onclick' => 'signOut();onClickStr()' )
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.