Easy Tutorial
❮ Att Caption Align Att Track Label ❯

HTML <form> target Attribute

HTML <form> Tag

Example

Submit a form that opens in a new window or tab, displaying the received response in the new window or tab:


Browser Support

All major browsers support the target attribute.


Definition and Usage

The target attribute specifies a name or a keyword that indicates where to open the action URL, i.e., where to display the response received after submitting the form.

The target attribute defines the name or keyword of the browser context (such as a tab, window, or inline frame).


Differences Between HTML 4.01 and HTML5

HTML5 supports the target attribute.

In HTML 4.01, the target attribute was deprecated.

Note: In HTML5, frame and frameset are no longer supported, so the values _parent, _top, and framename are mostly used for iframes.


Syntax

Attribute Values

Value Description
_blank Opens in a new window/tab.
_self Opens in the same frame. (Default)
_parent Opens in the parent frame.
_top Opens in the full window.
framename Opens in a specified iframe.

❮ Att Caption Align Att Track Label ❯