Search code examples
htmlfirefoxstandards-compliance

How to I add a line feed to a title style tooltip in firefox?


Firefox does not seem to support line feeds in the title attribute. I have tried \r, \r\n, \n, 
, 
, and still found nothing that works.

Does anyone have a hack to get around this?


Solution

  • There is nothing is the spec about how exactly browsers have to display the value in title attributes.

    Is simply says:

    Values of the title attribute may be rendered by user agents in a variety of ways. For instance, visual browsers frequently display the title as a "tool tip"

    (Emphasis mine)

    So, not only is there nothing about line breaks, but the actual behavior of "tool tip" is not mandatory.