Change an input's HTML5 placeholder color with CSS
Chrome supports the placeholder attribute on input[type=text]
elements (others probably do too).
But the following CSS doesn't do diddly squat to the placeholder's value:
input[placeholder], [placeholder], *[placeholder] {
color: red !important;
}
<input type="text" placeholder="Value">
Is there a way to change the color of the placeholder text?
I'm already using the jQuery placeholder plugin for the browsers that don't support the placeholder attribute natively.
CSS
- asked 9 years ago
- B Butts
Your Answer