Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Programmatically displaying HTML element titles

Is there a javascript way to display or hide element title (defined as an html attribute), as if the mouse was hovering above said dom element, without actually involving the mouse?

Thanks in advance.

like image 268
Dennis Kreminsky Avatar asked Jan 21 '11 23:01

Dennis Kreminsky


2 Answers

Not with native tooltips/titles. But there are jQuery plugins like this which let you cutomize and control them.

like image 70
Tim Schmelter Avatar answered Nov 02 '22 00:11

Tim Schmelter


I would use an absolutely positioned DIV that looks like the native tooltip and contains the same text as an alternative. It should be fairly trivial to loop through all elements and create a DIV for each one that has a title attribute.

Very little hassle and no JavaScript plugins required.

like image 33
Sparafusile Avatar answered Nov 01 '22 23:11

Sparafusile