I hate ASP.NET html helpers generate name and identifier attributes in the same case as POCO properties.
Most developers typically use lowercase values ββfor name and identifier, but I cannot find a way to do this in ASP.NET MVC.
Looking at the source shows that there is no way to override this functionality, but I could be wrong.
Is it possible?
EDIT : I will be more specific, with examples of what I'm talking about, since there seems to be some kind of confusion.
My model looks like this:
public class Customer { public string FirstName { get; set; } public string LastName { get; set; } }
In my opinion, I use Html herlpers as follows:
@Html.InputFor(m => m.FirstName)
This creates markup that looks like this:
<input type="text" name="FirstName" id="FirstName" value="" />
I hate that the FirstName property is capitalized. In an ideal world, I would like to override the generation of this attribute value so that I can force it to say "firstName" instead.
I do not want to change the POCO property names to lowercase. So most of the ASP.NET MVC framework is extensible and customizable - is it something that isn't there?
source share