The name attribute of the IFAME element defines a unique name for the iframe.
<iframe src="example.html" name="test"> - </iframe>
| Attribute | Value | Explanation |
|---|---|---|
| name=" " | frame name | arbitrary name |
Frame name
The frame name is used for the target attribute of the A element and the target attribute of the FORM element.
<ul> <li><a href="iexample_a.html" target="top">The red page opens in the top frame</a></li> <li><a href="iexample_b.html" target="top">The green page opens in the top frame</a></li> <li><a href="iexample_c.html" target="top">The yellow page opens in the top frame</a></li> </ul> <ul> <li><a href="iexample_a.html" target="bottom">The red page opens in the bottom frame</a></li> <li><a href="iexample_b.html" target="bottom">The green page opens in the bottom frame</a></li> <li><a href="iexample_c.html" target="bottom">The yellow page opens in the bottom frame</a></li> </ul> <p><iframe src="iexample_a.html" width="300" height="80" name="top">Alternate content</iframe></p> <p><iframe src="iexample_a.html" width="300" height="80" name="bottom">Alternate content</iframe></p>