You are here: Reference > HTML > attributes > INCREMENTAL (input:search)

INCREMENTAL attribute (input:search)

Browser support:
Specifies what type of user actions fire the onsearch event.
Regardless of this attribute, the onsearch event handler is fired when the user presses the Enter key on an input:search field. If the incremental flag is set, changing the contents of an input:search field fires the onsearch event as well.

Possible values:

This attribute has no values.
Specifying the INCREMENTAL attribute with an arbitrary value has the same effect as specifying it with no value.
For example, all of the following declarations have the same effect: incremental, incremental="true", incremental="false", incremental="on", incremental="incremental".
Although Boolean attributes may be used with no value in HTML, for XHTML compatibility, always use the INCREMENTAL attribute in the following format: incremental="incremental".

Example HTML code 1:

This example illustrates the use of the INCREMENTAL attribute:
    <script type="text/javascript">
        function OnSearch (input) {
            alert ("The current value of the search field: " + input.value);
    <form method="post" action="#URL#">
        What to find: 
        <input type="search" name="search" autosave="" 
                results="10" incremental="incremental" onsearch="OnSearch (this)" />
        <br /><br />
        <input type="submit" value="Search" />
Did you find this example helpful? yes no

Supported by tags:

Related pages:

External links:

User Contributed Comments

Post Content

Post Content