ASP. NET Upload Component

Source: Internet
Author: User

The upload function is often used in Web development. Therefore, I spent some time writing a simple component. Components support the following features:
1. Supports file storage node groups. nodes in the same group are stored randomly (by default). You can also select nodes for storage.
2. storage nodes support four Storage Methods: relative site directories, Virtual Site directories, absolute local folder paths, and file servers.
3. You can customize the storage directory structure.
Web. config settings are as follows:

Code

<Uploadsettings>
<Group name = "default" maxsubdirs = "1000" pathformat = "{type}/{uploadtime}/">
<! -- Relative site directory -->
<Add name = "default_node1" uploadpath = "/upload/" host = "/upload/"/>
<! -- Site virtual directory -->
<Add name = "default_node2" uploadpath = "virtualupload/" host = "/virtualupload/" isvirtual = "true"/>
<! -- Absolute path of the local folder -->
<Add name = "default_node3" uploadpath = "E: \ uploadtest \" host = "/uploadtest/"/>
<! -- File server -->
<Add name = "default_node4" uploadpath = "\ 192.168.200.30 \ upload \ test \" host = "http://img1.example.com/"/>
</Group>
</Uploadsettings>

 

 

For detailed usage, see the example program and download it here.

--------------------------------------
Http://www.qwolf.com/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.