All Event Handlers
EVENT HANDLER: onSelect
onSelect
= myJavaScriptCode
Event handler for
Text
,
Textarea
The
onSelect
event handler is used to execute specified JavaScript code whenever the user selects some of the text within a text or textarea field. The
onSelect
event handler uses the following properties of the
Event
Object:
type
- indicates the type of event.
target
- indicates the target object to which the event was sent.
In the following example, selecting some of the text in the
Text
object causes the 'selectEvent' function to execute:
Code:
<INPUT TYPE="text" onSelect="selectEvent()">
Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information