换行符在< td title =""> [英] newline in <td title="">

查看:94
本文介绍了换行符在< td title ="">的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


可能存在重复:


$使用回车在HTML-tooltip> b

$ b

我想知道在使用TD的title属性时是否可以在工具提示中强制显示换行符。
类似于

I'd like to know if it's possible to force a newline to show in the tooltip when using title property of a TD. something like

<td title="lineone \n linetwo \n etc...">

可以这样做吗?

Can this be done?

推荐答案

现在应该可以与Internet Explorer,Firefox v12 +和Chrome 28 +一起使用了。

This should now work with Internet Explorer, Firefox v12+ and Chrome 28+

<img src="'../images/foo.gif'" 
  alt="line 1&#013;line 2" title="line 1&#013;line 2">

尝试JavaScript工具提示库以获得更好的结果,例如 OverLib

Try a JavaScript tooltip library for a better result, something like OverLib.

这篇关于换行符在&lt; td title =&quot;&quot;&gt;的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆