I have this code which converts some text to lower case but is it possible to convert to 1st character to a capital letter followed by the remaining characters being lower case?
NWF$(document).ready(function() {
NWF$('#' + varTitle).change(function() {
this.value = this.value.toLowerCase();
});
});
Thanks to Ulysse BN , I got the hint to use the following
this.value = this.value[0].toUpperCase() + this.value.slice(1).toLowerCase()
which works excellent but if you wanted to use VGA as capital then this would not be possible, it is a catch 22 situation. Just wanted to avoid users from typing everything in capital (I hate it).