Wrap long-text in drop-down list?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have legibly long text in a drop-down list on my asp.net page. it violates the UI boundary and goes beyond the allocated region of UI. Is there anyway I can wrap [not trim] it using CSS or javascript ? I must display the entire string, no matter how long it is. 回答1: Longer answer: yes. You can use not default element, but make your own with JavaScript and CSS. Your custom droplist element should contain few divs (or other HTML elements) as droplist items. When you'll set fixed width to droplist's cell, text will wrap inside. One example is