Let's say we have this code:
<form action='' method='POST' enctype='multipart/form-data'>
<input type='file' name='userFile'><br>
<input type='submit' name='upload_btn' value='upload'>
</form>
which results in this:
When the user clicks the 'Browse...' button, a file search dialog box is opened:
The user will select the file either by double-clicking the file or by clicking the 'Open' button .
Is there a Javascript Event that I can use to be notified after after the file is selected?
Listen to the change event.
input.onchange = function(e) {
..
};