CodyBugstein
CodyBugstein

Reputation: 23372

How do you style the text inputted to an input text field?

There are lots of great tutorials on how to apply nice styles to input type="text" fields in HTML.

However I'd like to know, how do you style the actual text the user puts into the field? For example, this input box demo from DesignWithPc.

I've expanded the input box but I want the text typed in to match the size of the box (among other desired styling).

How do I do this?

Upvotes: 1

Views: 220

Answers (2)

user1278767
user1278767

Reputation:

You can always achieve this by setting few CSS properties like below

.awesome-text-box {
    line-height: 20px;
    font-size:16px;
    color: #515151;
}

Upvotes: 0

Patrick Allen
Patrick Allen

Reputation: 2178

Just change the font-size for that text box.

.awesome-text-box{
    font-size: 30px;
}

This will set the font size of the .awesome-text-box textfield to 30px;

Upvotes: 2

Related Questions