File upload Jquery WebApi

后端 未结 2 1485
忘了有多久
忘了有多久 2020-12-03 08:12

I used this following code to upload file to server, but the file is not uploaded.

Html:

      
&l
2条回答
  •  醉酒成梦
    2020-12-03 08:55

    Your javascript isn't referencing the correct file input control.

    You need to change this var opmlFile = $('#opmlFile')[0];

    To this var opmlFile = $('#myFile')[0];

提交回复
热议问题