Javascript examples for jQuery Method and Property:children
Get the filename of the dragged-in file
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript" src="https://code.jquery.com/jquery-1.5.2.js"></script> <script type="text/javascript"> $(function(){//from w w w .jav a 2 s .c o m $('#foo').change(function () { console.log(this.value, $(this).val()); }); }); </script> </head> <body> <input type="file" id="foo"> </body> </html>