can we call a javascript function by clicking open button of browse of html?
Hi guys开发者_开发知识库 actually I want to call a function by clicking on open button of browse field of HTML.Is it possible,if yes then provide me information
No. The "Browse" button is not accessible via JS (neither is just the text field next to it).
File uploads fields are very restricted not only regarding JS access - you cannot even style them properly.
Basically there is restriction on browse button, but there is a solution by "onchange" event to call another js function. And you can do as you want, e.g: gmail file upload attachment, and shows all uploaded files and you can deselect each of them, so these type of js operation can be perform by OnChange method.....
and there is a lot of example to do work with browse button.altering on type=file
精彩评论