ASP.net
Awesome
Learn
Forum
Buy
Demos
Sign In
☾
☀
Switch to
Dark
Light
Mode
this site works best with javascript enabled
Ask Question
EditorFor helper generating extra html for the textbox
Title:
B
I
{code}
?
I am using the Html.EditorFor helper on my login page and besides the textbox input it generates a lot of extra html around it.
Save Changes
Cancel
c4
asked at 04 Mar 2019
the `EditorFor` helper will use a template based on the type of the property, I presume you copied the EditorTemplates folder from our demos, and the `String.cshtml` template is being used which also has a `_FieldLayout.cshtml` that generates a label and validation span next to it. You can use the `Html.TextBoxFor` helper instead or use the `UiHint("templName")` attribute to indicate a different template
at 04 Mar 2019
Omu
Allright, i did that so, thanks for the Support, Sir.
at 04 Mar 2019
c4
Answers
please
Sign In
to leave an answer
By accessing this site, you agree to store cookies on your device and disclose information in accordance with our
cookie policy
and
privacy policy
.
OK