I first wrote a & amp; lt; inputtype & quot; file & quot; name & quot; file & quot; id & quot; fileupdate & quot; & amp; gt; then I wrote a tag named a. the content written in jquery is {code ...} however, there is no response after clicking? Okay, in the end, we can only use abs to locate and solve the problem... the effect is achieved... I first wrote
Then I wrote a tag. the content written in jquery is
$('a').on('click', '', function() { $('#fileupdate').click();});
However, there is no response after clicking?
Well, in the end, we can only use abs positioning to solve the problem... the effect is achieved, and it is a little unhappy.
After selecting a file, what does jquery use to trigger my next operations, such as getting a file. What triggers do I use?
Reply content:
First, I wrote
Then I wrote a tag. the content written in jquery is
$('a').on('click', '', function() { $('#fileupdate').click();});
However, there is no response after clicking?
Well, in the end, we can only use abs positioning to solve the problem... the effect is achieved, and it is a little unhappy.
After selecting a file, what does jquery use to trigger my next operations, such as getting a file. What triggers do I use?
Refer to this question
Http://segmentfault.com/q/1010000004322570
Click events generated by js cannot bring up the Upload file selection box.
You can observe the click events generated by js.event.isTrusted == falseAnd the actual click events in your browserevent.isTrusted == true
You can call the click () method on the hidden file input box.
The file bullet box cannot be directly triggered using Javascript.
But the subject wants to ask is to trigger the file bullet box with the tag.
In this way, you can