0
我试图采取以下方式文件输入:HTML文件上传
Input file: <input type="file" name="-f" id="fa">
我想补充的HTML链接(upload example)
,使其上传的示例文件上单击它,无需打开文件上传窗口。我试过以下内容:
<a href="" onclick="document.getElementById('fa').files[0].name = 'http://localhost/EXAMPLE/example.txt'; return false; ">(upload example)</a>
但它不工作。我该怎么办呢?