输入banner图图片脚本导航/分类

把文件上传按钮修改成自己喜欢的样式

1.在模态框里写文件的上传
2.修改input为file的样式
默认是“选择文件”,直接在后面显示文件的名字
解决:修改样式
方法如下:

  <form action="http://localhost:8080/GD/UploadAction_execute.action" method="post" enctype="multipart/form-data" name="uploadfile">
  <input type="file" name="my" id="file" value="浏览" style="display: none;"                      
   onchange="document.uploadfile.filePath.value=this.value"/>
  <input type="text" name="filePath" id="filePath"/>
  <input type="button" value="浏览..." onclick="document.uploadfile.my.click()"/><br>
  <input type="submit" value="上传" id="shangchuan">
  </form>

以上就是把文件上传按钮修改成自己喜欢的样式的详细内容,更多请关注Gxl网其它相关文章!