Yankue Team
Yankue Team

Reputation: 109

How to stop text being centered in HTML input box?

I'm making a big input box for the message in my contact form. On single-line text boxes, it works fine, but if you start to make it have multiple lines like the example, it always has the input in the middle.

<input type="text" style="width: 700px; height: 200px; font-size: 20px;" name="message" placeholder="Message" />

The text is vertically-centered. How can I change this? Thanks, Yankue.

Upvotes: 1

Views: 579

Answers (2)

Dupinder Singh
Dupinder Singh

Reputation: 7779

Please use <textarea>

<textarea type="text" style="width: 700px; height: 200px; font-size: 20px;" name="message" placeholder="Message" >
</textarea>

Upvotes: 2

Dan Knights
Dan Knights

Reputation: 8378

Using a <textarea> is probably the better option if you're going for a large body of text.

Upvotes: 2

Related Questions