How do i set the placeholder color of the active input, but that doesn’t work.. I tried following:
::-webkit-input-placeholder:active {
color: blue;
}
:-moz-placeholder:active {
color: blue;
}
:-ms-input-placeholder:active {
color: blue;
}
What i am after is same effect as the inputs on https://twitter.com/ ..
Solution so far:
:focus::-webkit-input-placeholder {
color: blue;
}
:focus:-moz-placeholder {
color: blue;
}
:focus:-ms-input-placeholder {
color: blue;
}
You are using
:activepseudo class, instead use:focusMy Fiddle
:activestyles only applies when you keep an elementclicked, so use:focusfor input fields…CSS
Preview