XF 2.0 Change tooltip text using jQuery?

Mr. Jinx

Well-known member
I would like to change the tooltip text with an onclick event.
The example below does not seem to work. The tooltip does not update.
Do I need to call something else to update this?

Code:
<a id="myid" href="javascript:void(0);" onclick="myfunction()" data-xf-init="tooltip" title="test"></a>

<xf:js>
    function myfunction() {
            jQuery('#myid').attr('title', 'changed'); }
</xf:js>
 
Back
Top Bottom