HTML <object> form Attribute

❮ HTML <object> tag

Example

An <object> element located outside a form (but still a part of the form):

<form action="/action_page.php" id="form1">
  First name: <input type="text" name="fname"><br>
  <input type="submit" value="Submit">
</form>

<object data="pic_trulli.jpg" width="300" height="200"></object>
Try it Yourself »

Definition and Usage

The form attribute specifies the form the object belongs to.

The value of this attribute must be equal to the id attribute of a <form> element in the same document.


Browser Support

Attribute
form Not supported Not supported Not supported Not supported Not supported

Syntax

<object form="form_id">

Attribute Values

Value Description
form_id Specifies the <form> element the <object> element belongs to. The value of this attribute must be the id attribute of a <form> element in the same document.

❮ HTML <object> tag
Copyright 1999-2023 by Refsnes Data. All Rights Reserved.