This question already has an answer here:
Is it possible to format an HTML tooltip?
E.g. I have a DIV with attribute title="foo!". When I have text-size of my browser zoomed in or out in, the text size of the tooltip remains unchanged. Is there a way to make the tooltip font scale with the browser setting?
I know this is an old post but I would like to add my answer for future reference. I use jQuery and css to style my tooltips: easiest-tooltip-and-image-preview-using-jquery (for a demo: http://cssglobe.com/lab/tooltip/02/) On my static websites this just worked great. However, during migrating to Wordpress it stopped. My solution was to change tags like
<br> and <span>
into this:<br> and <span>
This works for me.Mootools also has a nice 'Tips' class available in their 'more builder'.
No, it's not possible, browsers have their own ways to implement tooltip. All you can do is to create some div that behaves like an HTML tooltip (mostly it's just 'show on hover') with Javascript, and then style it the way you want.
With this, you wouldn't have to worry about browser's zooming in or out, since the text inside the tooltip div is an actual HTML, it would scale accordingly.
See Jonathan's post for some good resource.
It's not possible. But you can use some javascript libraries to create such tooltip, e.g. http://www.taggify.net/
Not sure if it works with all browsers or 3rd party tools, but I have had success just specifying "\n" in tooltips for newline, works with dhtmlx in at least ie11, firefox and chrome
I wrote this small javascript function that converts all of your native title tooltips into stylized nodes: http://jsfiddle.net/BurakUeda/g8r8L4vt/1/
Pros:
Cons:
It probably can be written more elegantly and may have a few lines that is unnecessary.
Also, stackoverflow code snippet thingy cannot parse the HTML code correctly, so check it on the jsfiddle link I provided.