MVC 控件样式的写法

具体什么控件用哪种方法.我也没总结.大家可以找找补充补充..不行就几种替换一下.

简单列出常用的几种:

@Html.TextAreaFor(model => model.Description, new { @class = "form-control", @rows = "3" })

@Html.LabelFor(model => model.PassWord, htmlAttributes: new { @class = "control-label col-md-2" })

@Html.EditorFor(model => model.Name, new { htmlAttributes = new { @class = "form-control" } })

@Html.EditorFor(model => model.IsDisabled, new { htmlAttributes = new { @class = "form-control" } })

原文地址:https://www.cnblogs.com/cxd1008/p/8383772.html