Upload the Same File
HTML
<input type="file" id="fileChooser">
JavaScript
var fileChooser = document.getElementById('fileChooser');
fileChooser.onclick = function () {
this.value = '';
};
fileChooser.onchange = function () {
if (this.value) {
alert('Uploaded!');
}
};