CVV
CVV

Reputation: 471

Set text field cursor to top

I have a simple form, Problem is why the cursor of the third text field is in the middle?

I want to be in the top left of the text field.

enter image description here

Here is my stylesheet:

.largeTextField{
    background-color: white;
    border: 1px solid rgb( 186, 186, 186 );
    border-radius: 5px;
    width: 330px;
    height: 100px;
    float: left;
}

Upvotes: 1

Views: 4334

Answers (2)

knocked loose
knocked loose

Reputation: 3304

Using input will cause the larger box to be used as a 1-line entry. You will need to define a textarea to allow multiple lines, like this:

<label>Content</label><br>
<textarea name="message" rows="10" cols="30"></textarea>

You can read more about inputs here.

Upvotes: 2

Lu&#237;s P. A.
Lu&#237;s P. A.

Reputation: 9739

Instead a <input> set a <textarea>

<input> - single line (row)

<textarea> - multiple lines (rows)

Upvotes: 4

Related Questions