Add a Single Line Input Field in HTML



Use the <isindex> tag to add a single-line input field. The HTML <isindex> tag is used for querying a document through a text field. The tag can be used anywhere but head tag is preferable. Note: It is a deprecated tag and should not be used.

The following are the attributes −

Attribute
Value
Description
Prompt
string
Label for the text field
Action
URL
used when a query needs to be sent to a different URL

Example

Try the following code −

<!Doctype html>
<html>
   <head>
      <title>HTML isindex Tag</title>
      <isindex prompt = "Search" />
   </head>
</html>
Updated on: 2020-05-30T22:59:17+05:30

651 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements