GO-Ve01
ServicesDevelopersBooksDictionaryPapersWikidataEncyclopediaSearchBabelCareersDeck

Search e01

One query across the encyclopedia, books, dictionary, papers, Wikidata and the developer library. Every hit carries its source.

6 results across 6 corpora for HTMLInputElement: setSelectionRange() method.

Dictionary 0

Papers 0

Wikidata 0

Developer library 6

` ` HTML input element

range of characters in the input element to a given string. A `selectMode` parameter is available to allow controlling how the existing content is affected. - setSelectionRange() - : Selects the specified range of characters within a textual input element. Does nothing for inputs which aren't presented as text input fields. - showPicker() - : Displays the browser picker for the input element that would normally

Document: getSelection() method

tical to `window.document.getSelection()`. Currently, `getSelection()` doesn't work on the content of textarea and input elements in Firefox. HTMLInputElement.setSelectionRange() or the `selectionStart` and `selectionEnd` properties could be used to work around this. Notice also the difference between _selection_ and _focus_. Document.activeElement returns the focused element. ## Examples ### Getting a Selection

HTMLInputElement

ement is suffering from a custom validity error, and does not validate. - setRangeText() - : Replaces a range of text in the input element with new text. - setSelectionRange() - : Selects a range of text in the input element (but does not focus it). - showPicker() - : Shows a browser picker for date, time, color, and files. - stepDown() - : Decrements the [`value`](/docs/Web/HTML/Reference/Elements/input#

MDN Web Docs mirror · CC BY-SA 2.5 (MDN) · https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement

HTMLInputElement: setSelectionRange() method

HTML DOM The **`setSelectionRange()`** method of the HTMLInputElement interface sets the start and end positions of the current text selection in an input element. This updates the selection state immediately, though the visual highlight only appears when the element is focused. This method updates the HTMLInputElement.selectionStart, HTMLInputElement.selectionEnd, and HTMLInputElement.selectionDirection properties

HTMLInputElement: select() method

ntListener("click", selectText); ``` ### Result Examples ## Specifications ## Browser compatibility ## See also - HTMLInputElement - HTMLInputElement.setSelectionRange()

HTMLInputElement: selectionDirection property

also - HTMLTextAreaElement.selectionDirection property - HTMLInputElement.selectionStart property - HTMLInputElement.selectionEnd property - HTMLInputElement.setSelectionRange method

JSON results · Services directory