I have a view in MVC3 with a TextBoxFor bound to my model like so:
<%=Html.TextBoxFor(m => m.SomeProperty, new { @readonly = "readonly" }) %>
How could I change this to be a textbox which would have style="display: none;" by default?
Html.TextBoxFor(m => m.SomeProperty, new { @readonly = "readonly", @hidden="true"})
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With