I have a form which is prepopulated from a very large table of addresses. Due to other reasons, this cannot be changed. The data (city name, in this case) is stored uppercase.
I need to translate it into proper case, first letter capitalised, the rest lowercase. Because users are continually correcting it and resubmitting.
EDIT: Please note, I'm not trying to change the value of the field, just the visual representation of it.
I could do it in PHP, or use JS, but I'd prefer to use CSS as it's the simplest least obtrusive way.
I've tried using text-transform:lowercase to drop the case of all the letters, then selector:first-letter {text-transform:uppercase} to raise the case of the first letter, but it's not working when applied to the input field. The first part (dropping the case of all letters) works fine, it goes from the value of "MANCHESTER" to "manchester" fine, but the second part with the pseudo selector won't work; as-in, it doesn't give me "Manchester".
input#address_3 {
text-transform:lowercase;
}
input#address_3:first-letter {
text-transform:uppercase;
}
Any help would be appreciated.
PS. See here: CSS text-transform capitalize on all caps