0

I have tried to insert a linefeed in the "title=" text in an <img> tag.

Both \n and <br /> are shown exactly as written.
Is there a trick to make it actually break the line?

2
Contributors
2
Replies
3
Views
8 Years
Discussion Span
Last Post by ingeva
0

From what I have read, there shouldn't actually be new lines in the title attribute. BUT if you do want to try, use "&#13;" which is a carriage return. In firefox, the return is converted to a space, but in IE you will see a line break in the tool tip (which I think is incorrect behaviour).

Hope that helps...

0

From what I have read, there shouldn't actually be new lines in the title attribute. BUT if you do want to try, use "
" which is a carriage return. In firefox, the return is converted to a space, but in IE you will see a line break in the tool tip (which I think is incorrect behaviour).

Hope that helps...

Thanks, I tried that, and you're right: In FireFox it's just a space.
There should be a better solution, but I guess I'll just not show any title but open a small message box instead.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.