开发者

How to default a select list to have no elements selected for use with jQuery bsmSelect plugin

I'm using the jQuery bsmSelect plugin to give my users a convenient way to select multiple options from a select-drop-down list. It works well, except I need it to star开发者_运维问答t with nothing selected by default. Anyone know how this can be accomplished?

bsmSelect intro: http://www.ryancramer.com/journal/entries/select_multiple/


HTMLSelectElement.selectedIndex = -1;

The ordinal index of the selected option, starting from 0. The value -1 is returned if no element is selected. If multiple options are selected, the index of the first selected option is returned.

http://www.w3.org/TR/DOM-Level-2-HTML/html.html#ID-94282980

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜