Jquery uploadify插件可选参数的详细介绍
- 博客分类:
- WEB前端
- JavaScript
以下是可选项的参数说明:(红色的属性代表常用的)
<wbr></wbr>
1 |
uploader |
上传控件的主体文件,flash控件 <wbr><wbr> 默认值='uploadify.swf'</wbr></wbr> |
2 |
script <wbr></wbr> |
相对路径的后端脚本,它将处理您上传的文件。 绝对路径前缀或'/'或'http'的路径 <wbr> 默认值='uploadify.php'</wbr> |
3 |
checkScript <wbr></wbr> |
检查该文件是否已经选择驻留在服务器上。 |
4 |
scriptData <wbr></wbr> |
可提供URL传递参数。用来传递get参数。例如: <wbr> index.jsp?id=1&action=uploadify可以设置成:</wbr> 'script': 'index.jsp', 'scriptData':{'id':1,'action':'uploadify'}, 注:要设置‘method’:‘GET’. <wbr></wbr> |
5 |
fileDataName <wbr></wbr> |
<wbr>您的文件在上传服务器脚本阵列的名称。<br><wbr><wbr> 默认值='Filedata'</wbr></wbr></wbr> |
6 |
method <wbr></wbr> |
<wbr>设置为发送到后端脚本的方法。要么'get'或post'。</wbr> <wbr><wbr> 默认值'post'</wbr></wbr> |
7 |
<wbr></wbr> |
<wbr>?</wbr> |
8 |
folder <wbr></wbr> |
您想将文件保存到的路径。考虑到安全问题,一般并不在客户端设定后供服务器得到所存的路径。我试了下。这个参数好像以get的方式传递的。设定post得不到这个值。 |
9 |
queueID <wbr></wbr> |
<wbr>文件队列ID。与div的id一致。</wbr> |
10 |
queueSizeLimit <wbr></wbr> |
限制在一次队列中的次数(可选定几个文件)。默认值= 999,而一次可传几个文件有 simUploadLimit属性决定。 |
11 |
multi <wbr></wbr> |
是否允许同时上传多文件,可设定true或false。 <wbr> 默认false。设定true时,选中的文件是当前项。</wbr> |
12 |
auto <wbr></wbr> |
选定文件后是否自动上传,可设定true或false。 <wbr> 默认false</wbr> |
13 |
fileDesc <wbr></wbr> |
出现在上传对话框中的文件类型描述。与fileExt需同时使用 |
14 |
fileExt <wbr></wbr> |
支持的格式,启用本项时需同时声明fileDesc。 如:‘*.rar,*.doc <wbr></wbr> |
15 |
sizeLimit <wbr></wbr> |
控制上传文件的大小,单位byte |
16 |
simUploadLimit <wbr></wbr> |
多文件上传时,同时上传文件数目限制。默认1 <wbr> 一次可传几个文件。</wbr> |
17 |
buttonText <wbr></wbr> |
默认按钮的名字。默认BROWER |
18 |
<wbr></wbr> |
使用图片按钮,设定图片的路径即可。 |
19 |
hideButton <wbr></wbr> |
上传按钮的隐藏。true 或false。默认flase |
20 |
rollover <wbr></wbr> |
<wbr>?</wbr> |
21 |
width <wbr></wbr> |
<wbr>按钮图片的长度。默认 110</wbr> |
22 |
height <wbr></wbr> |
<wbr>按钮图片的高度。默认 30</wbr> |
23 |
wmode <wbr></wbr> |
<wbr>背景透明transparent 与不透明opaque设定。默认 不透明</wbr> <wbr></wbr> |
24 |
cancelImg <wbr></wbr> |
<wbr>取消按钮。设定图片路径。默认cancel.png</wbr> <wbr></wbr> <wbr></wbr> |
25 |
onInit <wbr></wbr> |
函数, 初始化时的状态。 onInit: function() {<wbr></wbr> $("#id").html("上传前");}, |
26 |
onComplete <wbr></wbr> |
event: 事件对象 queueID: 完成文件的唯一标识符。 fileObj: <wbr></wbr> <wbr> • <strong>name</strong> – 文件名</wbr> <wbr> • <strong>filepath</strong> –上传路径</wbr> <wbr> • <strong>size</strong> – 文件大小</wbr> <wbr> • <strong>creationDate</strong> – 文件创建时间</wbr> <wbr> • <strong>modificationDate</strong> –<a name="OLE_LINK9"></a><a name="OLE_LINK8">文件最近修改时间</a></wbr> <wbr> • <strong>type</strong> –文件的扩展名</wbr> response: 服务器回调的数据 data: <wbr></wbr> <wbr> • <strong>fileCount</strong> – The total number of files left in the queue</wbr> <wbr> • <strong>speed</strong> – 平均上传速度 KB/s</wbr> 如: onComplete: function(event, queueID, fileObj) { <wbr> alert("文件:" +fileObj.name + "上传失败");<wbr><wbr>}</wbr></wbr></wbr> <wbr></wbr> |
27 |
onSelectOnce <wbr></wbr> |
函数:可传递二个参数 event: The event object. data: An object containing details about the select operation. <wbr> • <strong>fileCount</strong> – The total number of files in the queue</wbr> <wbr> • <strong>filesSelected</strong> – The number of files selected in the select operation</wbr> <wbr> • <strong>filesReplaced</strong> – The number of files that were replaced in the queue</wbr> <wbr> • <strong>allBytesTotal</strong> – The total number of bytes for all files in the queue</wbr> <wbr></wbr> |
28 |
onCancel <wbr></wbr> |
函数:可传递四个参数 event: The event object. queueID: The unique identifier of the file that was cancelled. fileObj: An object containing details about the file that was selected. <wbr><wbr> • <strong>name</strong> – The name of the file</wbr></wbr> <wbr><wbr> • <strong>size</strong> – The size in bytes of the file</wbr></wbr> <wbr><wbr> • <strong>creationDate</strong> – The date the file was created</wbr></wbr> <wbr><wbr> • <strong>modificationDate</strong> – The last date the file was modified</wbr></wbr> <wbr><wbr> • <strong>type</strong> – The file extension beginning with a '.'</wbr></wbr> <wbr></wbr> data: Details about the file queue. <wbr><wbr> • <strong>fileCount</strong> – The total number of files left in the queue</wbr></wbr> <wbr><wbr> • <strong>allBytesTotal</strong> – The total number of bytes left for all files in the queue</wbr></wbr> <wbr></wbr> |
29 |
onClearQueue <wbr></wbr> |
函数:可传递一个参数 event: The event object. |
30 |
onQueueFull <wbr></wbr> |
函数:可传递二个参数 • event - The event object. • queueSizeLimit - The maximum size of the queue. <wbr></wbr> |
31 |
onError <wbr></wbr> |
<wbr></wbr> event: The event object. queueID: The unique identifier of the file that was errored. fileObj: An object containing details about the file that was selected. <wbr> • <strong>name</strong> – The name of the file</wbr> <wbr> • <strong>size</strong> – The size in bytes of the file</wbr> <wbr> • <strong>creationDate</strong> – The date the file was created</wbr> <wbr> • <strong>modificationDate</strong> – The last date the file was modified</wbr> <wbr><strong>• type</strong> – The file extension beginning with a '.'</wbr> errorObj: An object containing details about the error returned. <wbr><strong>• type</strong> – Either 'HTTP', 'IO', or 'Security'</wbr> <wbr><strong>• info</strong> – An error message describing the type of error returned</wbr> <wbr></wbr> |
32 |
onOpen <wbr></wbr> |
函数:可传递三个参数 event: The event object. queueID: The unique identifier of the file that was opened. fileObj: An object containing details about the file that was selected. <wbr> • <strong>name</strong> – The name of the file</wbr> <wbr> • <strong>size</strong> – The size in bytes of the file</wbr> <wbr> •<wbr><strong>creationDate</strong> – The date the file was created</wbr></wbr> <wbr> • <strong>modificationDate</strong> – The last date the file was modified</wbr> <wbr> • <strong>type</strong> – The file extension beginning with a '.'</wbr> <wbr></wbr> |
33 |
onProgress <wbr></wbr> <wbr></wbr> |
函数:可传递四个参数 event: The event object. queueID: The unique identifier of the file that was updated. fileObj: An object containing details about the file that was selected. <wbr> • <strong>name</strong> – The name of the file</wbr> <wbr> • <strong>size</strong> – The size in bytes of the file</wbr> <wbr> • <strong>creationDate</strong> – The date the file was created</wbr> <wbr> • <strong>modificationDate</strong> – The last date the file was modified</wbr> <wbr> • <strong>type</strong> – The file extension beginning with a '.'</wbr> <wbr></wbr> data: An object containing details about the upload and queue. <wbr> • <strong>percentage</strong> – The current percentage completed for the upload</wbr> <wbr> • <strong>bytesLoaded</strong> – The current amount of bytes uploaded</wbr> <wbr> • <strong>allBytesLoaded</strong> – The current amount of bytes loaded for all files in the queue</wbr> <wbr> • <strong>speed</strong> – The current upload speed in KB/s</wbr> <wbr></wbr> |
34 |
onSelect <wbr></wbr> <wbr></wbr> |
event: The event object. queueID: The unique identifier of the file that was selected. fileObj: An object containing details about the file that was selected. <wbr> • <strong>name</strong> – The name of the file</wbr> <wbr> • <strong>size</strong> – The size in bytes of the file</wbr> <wbr> • <strong>creationDate</strong> – The date the file was created</wbr> <wbr> • <strong>modificationDate</strong> – The last date the file was modified</wbr> <wbr> • <strong>type</strong> – The file extension beginning with a '.'</wbr> <wbr></wbr> |
35 |
onAllComplete <wbr></wbr> <wbr></wbr> |
<wbr></wbr> event: The event object. data: An object containing details about the upload process. <wbr> • <strong>filesUploaded</strong> – The total number of files uploaded</wbr> <wbr> • <strong>errors</strong> – The total number of errors while uploading</wbr> <wbr> • <strong>allbytesLoaded</strong> – The total number of bytes uploaded</wbr> <wbr> • <strong>speed</strong> – The average speed of all uploaded files</wbr> <wbr></wbr> |
36 |
onCheck <wbr></wbr> |
函数:可传递五个参数 <wbr></wbr> event: The event object. checkScript: The path to the file checking script. fileQueue: A file queue object consisting of<wbr> key/value pairs with the queue ID as the key and the filename as the value.</wbr> folder: The path to the upload folder. single: True if only one file is being uploaded from the queue. |
发表评论
-
在IE6下js设置 option selected属性:unspecified error(未指明的异常)”
2011-06-15 10:45 904今天在做项目的时候,用IETest在IE6下面发现有如下错误: ... -
CSS的渲染效率–高效的CSS优化
2011-06-15 10:56 713链接地址:http://woshao.com/ ... -
最全的CSS浏览器兼容问题
2011-06-15 13:03 665链接地址:http://woshao. ... -
四大游览器兼容问题综合实例
2011-06-26 11:02 769转载地址:http://www.css-js.com/thre ... -
WEB设计师常用的设计模式
2011-06-26 11:13 846原文地址:http://woshao.com/article/ ... -
推荐一个全自动在线做gif进度条
2011-06-27 17:48 3302今天在网上寻找进度条,发现有很多打包的都差不多,没有什么灵活性 ... -
jquery.form.js 遇到的奇怪问题
2011-11-17 11:16 1185我的这个jquery.form.js不知道是哪个版本的 觉 ... -
js 小数计算误差
2011-12-07 20:52 1308今天在做有关基金财务数据的计算校验时,发现了js在计算小数时的 ... -
JavaScript 原型
2011-12-11 14:07 1008理解JavaScript原型 发布时间:2011-12-10 ...
相关推荐
jquery uploadify插件Demo
Jquery Uploadify使用参数详解
HTML5 PHP jquery uploadify上传文件,带进度条,author:吕大豹。仿照uploadify写的,www.codesc.net已做过修正,本例的配置参数均与uploadify官网一致,参照官网的api就可以了,直接把文件夹上传到支持php的服务器...
jquery uploadify插件多文件上传(带代码) 写着挺清楚的,可以借鉴看看!
一直以来jquery uploadify上传插件都不支持中文,每次都用图片代替也没感觉什么,但是最近开发的项目中有些特殊要求,不得不使用中文,于是中文支持版就出来了,这个是基于uploadify 2.1.4版修改的,请朋友们给点力,我赚点...
jquery插件
jquery Uploadify jsp 官网例子中没有jsp 开始了解的人不知道怎么用jqueryUploadify可以看这个例子很简单
JQuery uploadify 实现文件批量上传完整例子,所有js,和uploadify插件js 都放在这个例子中
使用jquery uploadify插件需要的js和css还有falsh和png
这是一款图片上传的jquery插件,使用 起来还是很方便的,代码实现了图片上传后显示。
jQuery上传附件插件uploadify3.2.zip
uploadify功能强大,支持多文件、批量上传、状态进度条等,提供前端文件限制相关设置。由于是flash环境全面支持asp、asp.net、php等平台。 该文件为uploadify for asp的demo,解压后即可运行。
该uploadify为目前官网最新版本,由鄙人修改后,可以支持buttonText属性为中文
Uploadify3.1 上传控件详细api
jquery上传插件Uploadify3.2中文详细参考手册,一款jQuery的无刷新上传插件
jQueryUpLoadify +NET 4.0,自己整合了,可以直接拿来使用!
jquery uploadify java
文件上传功能基于jquery uploadify+ajax+ashx+flash技术实现,功能庞大,并具有良好的移植性。其能够一次性选择多个文件上传,查看上传进度,控制文件上传类型和大小,限制上传数量,接受服务器反馈信息,为每一步...
Uploadify html5 官网下载 竟然要收费,太可气了,这个是根据官网API做的和uploadify一样基于html5 的上传插件。部署很简单。