a simple js fileUpload
JavaScript PHP
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
test
README.md
fileUpload.js

README.md

一个简单的文件上传组件

  • 基于KISSY 1.1.6

Example

K.use( 'fileUpload', function(){
    var formID = 'fileUpload',
    url = 'fileHandle.php',
    submit = 'formSubmit';

    var uploader = new K.fileUpload( url, formID, function( data ){
        console.log( data );
    });
    K.one( '#' + submit ).on( 'click', function(){
        uploader.upload();
        return false;
    });
});