zoukankan      html  css  js  c++  java
  • MVC 图片上传总是request.files.count() 等于0

    原因是因为自己的form表单内没有添加

    enctype = "multipart/form-data"

        @using (Html.BeginForm("UpLoadImg", "FamousStory", FormMethod.Post, new { enctype = "multipart/form-data", name = "upform", id = "upform" }))
        {
            <table align="center" style=" 700px; text-align: center; border-style: ridge;
                border- 3pt">
                <th colspan="3">
                    <font color="red" size="25" align="left">单一图片分类上传</font>
                </th>
                <tr>
                    <td align="center">
                        <input type="file" id="img" name="img" xml:lang />
                        <select name="ImgSource" id="ImgSource">
                            @if (imglist != null || imglist.ToList().Count > 0)
                            {
                                foreach (var item in imglist)
                                {                                                               
                                <option value="@item.ImgSource">@item.TypeName </option>
                                }
                            }
                        </select>
                        <input type="button" value="开始上传" id="upload" name="upload" onclick="UpLoad()" xml:lang />
                    </td>
                </tr>
            </table>
        }

  • 相关阅读:
    image 和 barplot 的组合
    par函数mgp 参数-控制坐标轴的位置
    R语言绘图时的边界碰撞问题
    R语言绘制花瓣图flower plot
    mothur 计算稀释性曲线
    R语言 vegan包计算物种累计曲线
    R语言数据框小技巧
    tophat-fusion 鉴定融合基因
    FusionCancer-人类癌症相关的融合基因的数据库
    rrnDB数据库简介-16S基因多拷贝数的证据
  • 原文地址:https://www.cnblogs.com/lewisli/p/2523956.html
Copyright © 2011-2022 走看看