开发者

problem during uploading avi or mpeg files in <form> tag

开发者 https://www.devze.com 2022-12-23 03:23 出处:网络
when i try to upload two files in the form, it doesn\'t happen!!! here is my code <input type=\"file\" name=\"video\" />

when i try to upload two files in the form, it doesn't happen!!! here is my code

<input type="file" name="video" />

<input type="file" name="picture" />

<input type="submit"  class="input" value="Save" />

but when i post only one file, that's ok!开发者_如何学JAVA!! can somebody help me, pleaseee;)


Seeing that this question has not that much details, I'll assume that this might be your problem.

Make sure your form has enctype="multipart/form-data" as attribute and method must be POST

e.g.

<form name="fileUploadForm" action="/toMyAction" enctype="multipart/form-data" method="POST">
  <input type="file" name="video" />
  <input type="file" name="picture" />
  <input type="submit"  class="input" value="Save" />
</form>
0

精彩评论

暂无评论...
验证码 换一张
取 消