문제

I want to create a dropdownlist which have three static values: Select All, Text Only, Numeric only. After that I like to add a line with some padding (just to separate these options) and then add some dynamic options.

I am not sure how to do this, Can some body please help?

So far I have created a List<SelectListItem> in my view model, and populated the static values from BLL. But I am not sure how to add a divider line in the middle now, and append some dynamic options after that.

Thanks

도움이 되었습니까?

해결책

The normal select tag will not work like that, you will have to create custom dropdown using spans or divs.

See some examples here:

http://tympanus.net/codrops/2012/10/04/custom-drop-down-list-styling/

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top