In my HTML page I set the style of my text box as initial
for text-transform
property, But not working with initial
. I also test with other values like uppercase
, lowercase
, capitalize
works fine but with initial
no change. I want when user enter text into the text box text should input with first letter capital and remaining as he/she entered.
<!DOCTYPE html>
<html>
<head>
<style>
::-webkit-input-placeholder {
text-transform: initial;
}
:-moz-placeholder {
text-transform: initial;
}
::-moz-placeholder {
text-transform: initial;
}
:-ms-input-placeholder {
text-transform: initial;
}
input{
text-transform: initial;
}
</style>
</head>
<body>
<input type="text" placeholder="text" />
</body>
</html>
Also tried
<html>
<head>
<style>
input:first-letter {
text-transform: uppercase;
}
</style>
</head>
<body>
<input type='text' >
</body>
</html>
No luck.
etc but not for input element why its like that.
– Alfiza malek Mar 23 '17 at 06:45