• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Lesson 13. Creating Forms > Adding Multiple-Line Text Fields

Adding Multiple-Line Text Fields

Multiple-line text fields are used to collect larger amounts of information from a user. Typical multiple-line text fields collect comments and feedback from users. In this exercise, you will place a multi-line text field in the table inside the form.

1.
In the myform.htm document, type Address in the left cell of row 3 and press Tab.

The multiple-line text field will be inserted in same column as the single-line text boxes from the previous exercise.

2.
Choose Insert > Form Objects > Text Field.

A single-line text field is placed in the form and the property inspector shows Text Field properties.

3.
On the property inspector, select Multi line for the Type option.

In Dreamweaver, text fields are inserted as single-line fields by default; in order create multi-line fields, you must select Multi line from the property inspector.

4.
In the Name text box on the property inspector, replace textfield with address. In the Char Width text box, type 40.

When you use multiple-line text fields you will see an additional option on the property inspector. The Wrap drop-down menu is only available for multiple-line text fields. It is grayed-out for both single-line and password text fields. Wrap specifies how text that is typed into a multiple-line field is displayed if there is more text than will fit in the visible area. The options are Default, Off, Virtual, and Physical.

Default will use the browser default. This option is selected automatically when you select Multi line for the Type option.

Off will stop text from wrapping to the next line. Text will continue on one line until the Return key is pressed. (Off is typically the default setting.)

Virtual will wrap text to the next line, but wrap will not be applied to the data when it is submitted.

Physical will wrap text to the next line, and wrap will be applied to the data when it is submitted.

5.
In the Num Lines text box on the property inspector, type 4.

This option dictates how many lines will appear in the scrollable area. It does not limit the number of lines users can enter.

Your document should now look similar to the example shown here.

6.
Save the file and preview it in the browser.

Leave this file open for the next exercise.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint