How can I change the password box to disabled.
@Html.Editor("password")
something like
Html.TextBoxFor(model => model.User, new {disabled = "disabled"})
How can I change the password box to disabled.
@Html.Editor("password")
something like
Html.TextBoxFor(model => model.User, new {disabled = "disabled"})
You're close. You have to prefix your attributes with @
:
Html.TextBoxFor(model => model.User, new { @disabled = "disabled" })
You can read only text box using Html Attributes
@Html.TextBoxFor(model => model.User, new { @readonly="readonly", style = "width:80%;" })