jquery's Uploadify plug-in implementation of bulk upload version V3.2.1

Source: Internet
Author: User

You need the following configuration (including the introduction of the file) HTML:

<HTMLxmlns= "http://www.w3.org/1999/xhtml"><Headrunat= "Server">    <Metahttp-equiv= "Content-type"content= "text/html; charset=utf-8" />    <title></title>    <Scriptsrc= "Js/jquery-1.8.3.js"></Script>    <Scriptsrc= "Uploadify/jquery.uploadify.min.js"></Script>    <Scriptsrc= "Uploadify/jquery.uploadify.js"></Script>    <Linkhref= "Uploadify/uploadify.css"rel= "stylesheet" /></Head><Body>    <formID= "Form1"runat= "Server">        <Scripttype= "Text/javascript">            $(function () {                $('#file_upload'). uploadify ({'SWF': '/uploadify/uploadify.swf',//must be                    'Uploader': 'uploadhandler.ashx',//processing the background address of the uploaded image                    'cancelimg': 'Image/ico/uploadify-cancel.png',//Canceled Pictures                    'Auto': false//set to False to disable automatic upload, default true                    //Put your options here                });        }); </Script>        <inputtype= "File"name= "File_upload"ID= "File_upload" />         <ahref= "javascript:$" (' #file_upload '). Uploadify (' upload ', ' swfupload_0_1 ') ">Upload</a>| <ahref= "javascript:$ (' #file_upload '). Uploadify (' Stop ', ' swfupload_0_3 ')">Cancel Upload</a>    </form></Body></HTML>

Upload method is the upload method, the second parameter refers to the upload of one of the specified, fixed, only the back of 0-1 or 0-3 can change the representative of one, if more than one, need to separate the comma, such as:

Swfupload_0_1,swfupload_0_3

Background:
         Public voidProcessRequest (HttpContext context) {context. Response.ContentType="Text/plain"; //context. Response.Write ("Hello World");httppostedfile File= Context. request.files["Filedata"]; stringUploadpath =HttpContext.Current.Server.MapPath ("\\word") +"\\"; if(File! =NULL)            {                if(!directory.exists (Uploadpath))                {directory.createdirectory (Uploadpath); } file. SaveAs (Uploadpath+file.                FileName); //the operations that are stored in the database can be added here ... //If the following code is missing, the upload queue display will not disappear automatically after uploading successfully .Context. Response.Write ("1"); }            Else{context. Response.Write ("0"); }          }


Official API Address:
http://www.uploadify.com/documentation/
Chinese API Address:
Http://www.mamicode.com/info-detail-506696.html
Sample diagram:

Interested students can look at the official website

jquery's Uploadify plug-in implementation of bulk upload version V3.2.1

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.