使用EditorFor輸入欄的寬度我只是對如何設置輸入字段的MVC中的寬一些很好的建議:在MVC3
@Html.TextBoxFor(model => model.Status.RowKey, new { size = 200, disabled = "disabled", @readonly = "readonly" })
現在,我甲肝嘗試了另一種類型的字段,但它不「T工作:
@Html.EditorFor(model => model.Status.BrowserTitle, new { size = 80 })
我還要設置這個爲80個字符,但是當我這樣做的源不會改變,不顯示80
BEV
可能重複http://stackoverflow.com/questions/1625327/ editorfor-and-html-properties) – 2011-05-06 16:09:25
Look [another one](http://stackoverflow.com/questions/3735400/html-attributes-for-editorfor-in-asp-net-mvc) – 2011-05-06 16:10:36