Jobz
Jobz

Reputation: 462

Placeholder font style is coming as different for textfield and textarea

I have a form with a textfield and a textarea and both of them have a placeholder. But the font style of the placeholder is different as compared to the textfield and textarea. Please show me how to keep the same font style.

<form> 
    <input type="text" placeholder="just for testing the style">
    <textarea placeholder="just for testing the style"></textarea>
</form>

Upvotes: 1

Views: 3666

Answers (2)

alexrogers
alexrogers

Reputation: 1584

You need to set them to the same font family in the CSS:

textarea,
input[type=text] {
    font-family:Arial;
}

Upvotes: 2

ilmk
ilmk

Reputation: 592

You need to mention font family for textarea like here

css

textarea{font-family:arial;}

Upvotes: 1

Related Questions