'text-overflow' Example
<html> <body> <div id="myT" style="width:200; background-color:beige; overflow:hidden;"> <nobr>www.java2s.com<nobr> </div> <input type="button" value='text-overflow = "ellipsis"' onclick="myT.style.textOverflow = 'ellipsis'"> <input type="button" value='text-overflow = "clip"' onclick="myT.style.textOverflow = 'clip'"> </body> </html>