在上传文件时应用限制 [英] apply limit in uploading files

查看:109
本文介绍了在上传文件时应用限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





i想要在任何用户上传文件时申请限额,即100kb或mb



是应用于函数还是在web.config文件中

hey

i want to apply limit when any user upload their files i.e 100kb or mb

is this apply in function or in web.config file

推荐答案

谷歌搜索asp.net限制文件上传大小应该会给你更多信息。



关于代码项目的这篇文章也应该有所帮助:

限制ASP.NET中文件上传的大小 [ ^ ]
A google search for "asp.net limit file upload size" should give you more info.

This article on code project should help too:
Restrict the size of file uploads in ASP.NET[^]


可能是您检查文件可以支持的最大大小的文件上传属性。

例如。文件上传控件的ContentLeng属性,您可以检查最大值。

-SG
may be you check for the file upload property for max size the file can support.
eg. ContentLeng­ property of file upload control you can check for max value.
-SG


这篇关于在上传文件时应用限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆