jquery - How can I add tooltip on content of table -


i new java script. wanted add tooltip given below content. there 1 way of doing can adding title every td tag. how can add title every td same value. not allowed touch html code below written here automatic generated code using jtbale plugin.

<tbody> <tr class="jtable-data-row jtable-row-even">     <td>admin-ui</td>     <td>/admin/manage/client</td>     <td>client manager</td>     <td>used redirecting client management page</td>  </tr> <tr class="jtable-data-row">     <td>admin-ui</td>     <td>/admin/manage/configuration</td>     <td>configuration manager</td>     <td>used redirecting configuration page</td>  </tr> 

any appreciated.

you can add title-tag via .attr()-function , invoke tooltip after that:

$('table td').attr('title', 'testtitle').tooltip(); 

to expand tooltip width of it's content may have add following css:

.ui-tooltip{     max-width: 100%; } 

demo


Comments