jQuery change placeholder text color

You can’t really modify pseudo-selectors with JavaScript. You’ll have to modify an existing a <style> element.

If possible, make a class:

.your-class::-webkit-input-placeholder {
    color: #b2cde0
}

And add it to the element:

 $('input').addClass('your-class');

Leave a Comment