1. langFile: 'http://www.static-xxx.nu/uploader/uploadifyLang_en.js',//语言包的路径,能设置所有的提示文字
  2.  
  3. swf: 'http://www.static-xxx.nu/uploader/uploadify.swf',//[必须设置]swf的路径
  4.  
  5. uploader: '/uploadify/galleri.php',//[必须设置]上传文件触发的url
  6.  
  7. auto:false,//文件选择完成后,是否自动上传
  8.  
  9. buttonText:'Välj Filer',//上传按钮的文字
  10.  
  11. height: 30,//上传按钮的高和宽
  12.  
  13. width: 120,
  14.  
  15. formData:{},
  16.  
  17. buttonCursor: 'pointer',//上传鼠标hover后Cursor的形状
  18.  
  19. cancelImage: 'http://www.static-xxx.nu/uploadify-cancel.png',//[必须设置]取消图片的路径
  20.  
  21. checkExisting:'/uploader/uploadify-check-existing.php',//检查上传文件是否存,触发的url,返回1/0
  22.  
  23. debug: true,//debug模式开/关,打开后会显示debug时的信息
  24.  
  25. fileObjName:'file',
  26.  
  27. fileSizeLimit : 0,//文件的极限大小,以字节为单位,0为不限制。1MB:1*1024*1024
  28.  
  29. fileTypeDesc: 'Bild JPG',//允许上传的文件类型的描述,在弹出的文件选择框里会显示
  30.  
  31. fileTypeExts: '*.jpg',//允许上传的文件类型,限制弹出文件选择框里能选择的文件
  32.  
  33. method: 'post',//和后台交互的方式:post/get
  34.  
  35. multi: true,//是否能选择多个文件
  36.  
  37. queueID: 'fileQueue',//显示上传文件队列的元素id,可以简单用一个div来显示
  38.  
  39. queueSizeLimit : 999,//队列中允许的最大文件数目
  40.  
  41. progressData : 'all', // 'percentage''speed''all'//队列中显示文件上传进度的方式:all-上传速度+百分比,percentage-百分比,speed-上传速度
  42.  
  43. removeCompleted : true,//上传成功后的文件,是否在队列中自动删除
  44.  
  45. removeTimeout: 3,
  46.  
  47. requeueErrors : true,
  48.  
  49. postData: {},//和后台交互时,附加的参数
  50.  
  51. preventCaching : true,
  52.  
  53. transparent: true,
  54.  
  55. successTimeout : 30,//上传时的
  56.  
  57. timeoutuploadLimit:999//能同时上传的文件数目,
  58. overrideEvents: ['onSelectError', 'onDialogClose'],//重写方法,使原有方法不执行 用于自定义提示
  59. onDialogClose : function(swfuploadifyQueue) {//当文件选择对话框关闭时触发
  60.   if( swfuploadifyQueue.filesErrored > 0 ){
  61.   alert( '添加至队列时有'
  62.   +swfuploadifyQueue.filesErrored
  63.   +'个文件发生错误n'
  64.   +'错误信息:'
  65.   +swfuploadifyQueue.errorMsg
  66.   +'n选定的文件数:'
  67.   +swfuploadifyQueue.filesSelected
  68.   +'n成功添加至队列的文件数:'
  69.   +swfuploadifyQueue.filesQueued
  70.   +'n队列中的总文件数量:'
  71.   +swfuploadifyQueue.queueLength);
  72.   }
  73. }
  74. onDialogOpen : function() {//当选择文件对话框打开时触发
  75.   alert( 'Open!');
  76. }
  77. onSelect : function(file) {//当每个文件添加至队列后触发
  78.   alert( 'id: ' + file.id
  79.   + ' - 索引: ' + file.index
  80.   + ' - 文件名: ' + file.name
  81.   + ' - 文件大小: ' + file.size
  82.   + ' - 类型: ' + file.type
  83.   + ' - 创建日期: ' + file.creationdate
  84.   + ' - 修改日期: ' + file.modificationdate
  85.   + ' - 文件状态: ' + file.filestatus);
  86. }
  87. onSelectError : function(file,errorCode,errorMsg) {//当文件选定发生错误时触发
  88.   alert( 'id: ' + file.id
  89.   + ' - 索引: ' + file.index
  90.   + ' - 文件名: ' + file.name
  91.   + ' - 文件大小: ' + file.size
  92.   + ' - 类型: ' + file.type
  93.   + ' - 创建日期: ' + file.creationdate
  94.   + ' - 修改日期: ' + file.modificationdate
  95.   + ' - 文件状态: ' + file.filestatus
  96.   + ' - 错误代码: ' + errorCode
  97.   + ' - 错误信息: ' + errorMsg);
  98. }
  99. onQueueComplete : function(stats) {//当队列中的所有文件全部完成上传时触发
  100.   alert( '成功上传的文件数: ' + stats.successful_uploads
  101.   + ' - 上传出错的文件数: ' + stats.upload_errors
  102.   + ' - 取消上传的文件数: ' + stats.upload_cancelled
  103.   + ' - 出错的文件数' + stats.queue_errors);
  104. }
  105. onUploadComplete : function(file,swfuploadifyQueue) {//队列中的每个文件上传完成时触发一次
  106.   alert( 'id: ' + file.id
  107.   + ' - 索引: ' + file.index
  108.   + ' - 文件名: ' + file.name
  109.   + ' - 文件大小: ' + file.size
  110.   + ' - 类型: ' + file.type
  111.   + ' - 创建日期: ' + file.creationdate
  112.   + ' - 修改日期: ' + file.modificationdate
  113.   + ' - 文件状态: ' + file.filestatus
  114.   + ' - 出错的文件数: ' + swfuploadifyQueue.filesErrored
  115.   + ' - 错误信息: ' + swfuploadifyQueue.errorMsg
  116.   + ' - 要添加至队列的数量: ' + swfuploadifyQueue.filesSelected
  117.   + ' - 添加至对立的数量: ' + swfuploadifyQueue.filesQueued
  118.   + ' - 队列长度: ' + swfuploadifyQueue.queueLength);
  119. }
  120. onUploadError : function(file,errorCode,errorMsg,errorString,swfuploadifyQueue) {//上传文件出错是触发(每个出错文件触发一次)
  121.   alert( 'id: ' + file.id
  122.   + ' - 索引: ' + file.index
  123.   + ' - 文件名: ' + file.name
  124.   + ' - 文件大小: ' + file.size
  125.   + ' - 类型: ' + file.type
  126.   + ' - 创建日期: ' + file.creationdate
  127.   + ' - 修改日期: ' + file.modificationdate
  128.   + ' - 文件状态: ' + file.filestatus
  129.   + ' - 错误代码: ' + errorCode
  130.   + ' - 错误描述: ' + errorMsg
  131.   + ' - 简要错误描述: ' + errorString
  132.   + ' - 出错的文件数: ' + swfuploadifyQueue.filesErrored
  133.   + ' - 错误信息: ' + swfuploadifyQueue.errorMsg
  134.   + ' - 要添加至队列的数量: ' + swfuploadifyQueue.filesSelected
  135.   + ' - 添加至对立的数量: ' + swfuploadifyQueue.filesQueued
  136.   + ' - 队列长度: ' + swfuploadifyQueue.queueLength);
  137. }
  138. onUploadProgress : function(file,fileBytesLoaded,fileTotalBytes,
  139. queueBytesLoaded,swfuploadifyQueueUploadSize) {//上传进度发生变更时触发
  140. alert( 'id: ' + file.id
  141.   + ' - 索引: ' + file.index
  142.   + ' - 文件名: ' + file.name
  143.   + ' - 文件大小: ' + file.size
  144.   + ' - 类型: ' + file.type
  145.   + ' - 创建日期: ' + file.creationdate
  146.   + ' - 修改日期: ' + file.modificationdate
  147.   + ' - 文件状态: ' + file.filestatus
  148.   + ' - 当前文件已上传: ' + fileBytesLoaded
  149.   + ' - 当前文件大小: ' + fileTotalBytes
  150.   + ' - 队列已上传: ' + queueBytesLoaded
  151.   + ' - 队列大小: ' + swfuploadifyQueueUploadSize);
  152. }
  153. onUploadStart: function(file) {//上传开始时触发(每个文件触发一次)
  154.   alert( 'id: ' + file.id
  155.   + ' - 索引: ' + file.index
  156.   + ' - 文件名: ' + file.name
  157.   + ' - 文件大小: ' + file.size
  158.   + ' - 类型: ' + file.type
  159.   + ' - 创建日期: ' + file.creationdate
  160.   + ' - 修改日期: ' + file.modificationdate
  161.   + ' - 文件状态: ' + file.filestatus );
  162. }
  163. onUploadSuccess : function(file,data,response) {//上传完成时触发(每个文件触发一次)
  164.   alert( 'id: ' + file.id
  165.   + ' - 索引: ' + file.index
  166.   + ' - 文件名: ' + file.name
  167.   + ' - 文件大小: ' + file.size
  168.   + ' - 类型: ' + file.type
  169.   + ' - 创建日期: ' + file.creationdate
  170.   + ' - 修改日期: ' + file.modificationdate
  171.   + ' - 文件状态: ' + file.filestatus
  172.   + ' - 服务器端消息: ' + data
  173.   + ' - 是否上传成功: ' + response);
  174.  
  175. }

方法:

方法名 参数 描述
cancel(fileID, suppressEvent) fileID[String]:要取消文件的 ID。 检索文件 ID 的最简单方法是使用您要取消文件队列项的 id 属性。可以输入任意数量的文件 Id 作为参数。如果您输入 “*” 作为第一个参数, 该队列中的所有文件将会被都取消。如果没有文件 ID 作为参数设置,在队列中的第一个文件就会被取消。
suppressEvent[Boolean]: 如果设置为 true,onUploadCancel 事件将不会触发。 清除队列时,这非常有用。 取消队列中的文件(无论是否正在上传)
destroy() 销毁的实例的 Uploadify, 并返回到其原始状态的文件输入
disable(setDisabled) setDisabled[Boolean]:True为禁用按钮。False为启用按钮 禁用或启用浏览按钮。
settings(name, value, resetObjects) name[String]:要返回或更改设置的属性名称。只有设置了此参数,则将返回值。 value[String]:对当前name属性设 置的值 resetObjects[Boolean]:设置为true时更新的POSTDATA的对象,以清除现有值。否则,新的值将被添加到现有的对象中 注: 不能设置SWF属性 获取或设置Uploadify中的属性值
stop() 停止当前正在上传的文件
upload(fileID) fileID[String]:要上传文件的 ID。 检索文件 ID 的最简单方法是使用您要取消文件队列项的 id 属性。可以 输入任意数量的文件 Id 作为参数。如果您输入 “*” 作为第一个参数,该队列中的所有文件将会被都取消。如果没有文件 ID 作为参数设置,在队列中的第一个文件就会被取消。 上传的特定文件或在队列中 的所有文件。

uploadify3.1 参数 中文详解的更多相关文章

  1. [转]RSYNC 参数中文详解

    FROM : http://www.qiansw.com/rsync-cn.html rsync是一款好用的*nux文件同步工具.下面是其参数的中文解释. Rsync 参数选项说明 -v, --ver ...

  2. Nginx编译参数大全 configure参数中文详解

    ./configure --help--help 显示本提示信息--prefix=PATH 设定安装目录--sbin-path=PATH 设定程序文件目录--conf-path=PATH 设定配置文件 ...

  3. (转)x264参数中文详解(X264 Settings)

    0 解释x264命令可选项的用途和使用方法.同执行 x264 --fullhelp 显示顺序.本文主要翻译:mewiki.project357.com/wiki/X264_Settings,同时参考d ...

  4. Nginx配置文件nginx.conf中文详解(转)

    ######Nginx配置文件nginx.conf中文详解##### #定义Nginx运行的用户和用户组 user www www; #nginx进程数,建议设置为等于CPU总核心数. worker_ ...

  5. Nginx中文详解、配置部署及高并发优化

      一.Nginx常用命令: 1. 启动 Nginx          /usr/local/nginx/sbin/nginxpoechant@ubuntu:sudo ./sbin/nginx2. 停 ...

  6. jQuery Pagination Ajax分页插件中文详解(摘)

    jQuery Pagination Ajax分页插件中文详解 by zhangxinxu from http://www.zhangxinxu.com 本文地址:http://www.zhangxin ...

  7. Nginx配置文件nginx.conf中文详解【转】

    PS:Nginx使用有两三年了,现在经常碰到有新用户问一些很基本的问题,我也没时间一一回答,今天下午花了点时间,结合自己的使用经验,把Nginx的主要配置参数说明分享一下,也参考了一些网络的内容,这篇 ...

  8. Nginx配置文件中文详解

    ######Nginx配置文件nginx.conf中文详解##### #定义Nginx运行的用户和用户组 user www www; #nginx进程数,建议设置为等于CPU总核心数. worker_ ...

  9. Nginx安全相关配置和nginx.conf中文详解

    一.centos下redis安全相关 1.背景 在使用云服务器时,如果我们的redis关闭了protected-mode模式,被病毒攻击的可能会大大增加,因此我们使用redis时候,最好更改默认端口, ...

随机推荐

  1. \r \n有什么区别

    '\r'是回车,'\n'是换行,前者使光标到行首,后者使光标下移一格.通常用的Enter是两个加起来.下面转一篇文章. 回车和换行 今天,我总算搞清楚“回车”(carriage return)和“换行 ...

  2. BestCoder Round 59 (HDOJ 5500) Reorder the Books

    Problem Description dxy has a collection of a series of books called “The Stories of SDOI”,There are ...

  3. JavaScript--基本包装类型+Math对象

    1. 基本包装类型 1)为了便于操作基本类型值,ECMAScript提供了3个特殊的引用类Boolean, Number, String       每当读取一个基本类型值的时候,后台就会创建一个对应 ...

  4. union关键字 与大小端模式

    union 关键字(主要用来压缩空间,如果一些数据不可能同一时间同时用到,可是考虑使用union) union关键字声明的变量称之为联合体变量: (1)联合体变量只配置一个足够大的空间来容纳最大长度的 ...

  5. XDubg的配置与应用

    XDUG调试器配置与应用 1.什么是xbug xbug是一个开发源代码的php程序员调试器,可以用来跟踪,调试和分析Php程序的运行状况. Xbug(free) ZendDebugger(need m ...

  6. Mongodb增加权限管理

     前言: 随着列式存储理念的成熟,越来越多的开发者开始接纳mongodb,hbase这类大储存的分布式列式数据库.特别是mongodb的这种快速搭建,快速使用特点,使其得到更多人的青睐.本人主要通过官 ...

  7. 【转】Nginx windows下搭建过程

    Nginx windows下搭建过程 内容列表: 简要介绍 下载安装 配置测试 一.简要介绍 Nginx ("engine x") 是一个高性能的 HTTP 和 反向代理 服务器, ...

  8. C#中struct与class的区别详解

    转自:http://blog.csdn.net/justlovepro/archive/2007/11/02/1863734.aspx 有这么几点不同: 1.struct 是值类型,class是对象类 ...

  9. 摇滚吧HTML5!有声前端交互!(一)

    生命的伊始,婴儿用明亮的哭声宣告一个新生命的诞生,睁开双眼之前,一双小耳朵已经开始聆听这个世界.在如今的用户体验领域,几乎所有公司都会有视觉设计师,却鲜有注重听觉交互的公司.随着各大厂商对HTML5支 ...

  10. win8.1(64位) apache2.4.3+php5.6.3+mysql5.6安装

    win8.1(64位) apache2.4.3+php5.6.3+mysql5.6安装 http://blog.csdn.net/jiangzeyun/article/details/41676639