I have a input
and when I type something in it the text will have the same background color (white).
Does anyone know how I can edit this? I would like to put color black .
I have a input
and when I type something in it the text will have the same background color (white).
Does anyone know how I can edit this? I would like to put color black .
Just put the color
attribute as black
, here are two examples of how to change the color of input
,
Example: text with black color
input{
color: black;
}
<input type="text">
Example: text with red color
input{
color: red;
}
<input type="text">
It's simple, just put the CSS attribute color
of the input with the color you want. For text box type inputs, the color
property refers to the color of the text.
Something like:
input { color: white }
Or
input { color: #ffffff } /* forma pedante */
With jQuery:
$("input").css("color", "white");
You can also use more specific selectors, such as a class, or the input identifier.
Just use color in CSS:
<input type="text" style="color: black;">