码迷,mamicode.com
首页 > Web开发 > 详细

MVC4中下拉菜单和单选框的简单设计方法

时间:2014-08-23 15:23:10      阅读:282      评论:0      收藏:0      [点我收藏+]

标签:io   for   html   new   htm   ad   on   ef   c   

@Html.LabelFor(model => model.Gender)
@Html.DropDownListFor(model => model.Gender, new[] { new SelectListItem() { Text = "女生", Value = "女生" }, new SelectListItem() { Text = "男生", Value = "男生" }, })
@* @Html.RadioButton("Gender", "男") 帅哥 @Html.RadioButton("Gender", "女") 美女 @Html.RadioButton("Gender", "保密", true) 保密*@
@Html.ValidationMessageFor(model => model.Gender)

MVC4中下拉菜单和单选框的简单设计方法

标签:io   for   html   new   htm   ad   on   ef   c   

原文地址:http://www.cnblogs.com/yechangzhong-826217795/p/3931121.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!