You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I am migrating an old MVC razor project to use Bootstrap and have been finding this solution to the task great.
However, I have been trying to add additional attributes to an input control for a DateTime property type. I would typically do this as follows:
@html.EditorFor(model => model.DateTimeFrom, new { Attribute1 = "valueOfAttribute1"})
This is not working. The attribute isn't rendered at all in the resulting page. I believe this is down to this Bootstrap for MVC solution. Is it? Or am I using it incorrectly?
Kind regards.
Tomas
The text was updated successfully, but these errors were encountered:
Cringe :-( ... I feel bad posting this as an issue after now realising that it was more down to my lack of knowledge of MVC and Editor Templates and therefore nothing to do with how Bootstrap for MVC4 operates per se.
Hi,
I am migrating an old MVC razor project to use Bootstrap and have been finding this solution to the task great.
However, I have been trying to add additional attributes to an input control for a DateTime property type. I would typically do this as follows:
@html.EditorFor(model => model.DateTimeFrom, new { Attribute1 = "valueOfAttribute1"})
This is not working. The attribute isn't rendered at all in the resulting page. I believe this is down to this Bootstrap for MVC solution. Is it? Or am I using it incorrectly?
Kind regards.
Tomas
The text was updated successfully, but these errors were encountered: