<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<head>
<title>SWFUpload</title>
<link href="css/default.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="swfupload/swfupload.js"></script>
<script type="text/javascript" src="js/swfupload.queue.js"></script>
<script type="text/javascript" src="js/fileprogress.js"></script>
<script type="text/javascript" src="js/handlers.js"></script>
<script type="text/javascript">
window.onload = function() {
var settings = {
flash_url : "swfupload/swfupload.swf",//调用flash
upload_url: "../upload.php", //上传地址
post_params: {"PHPSESSID" : "<?php echo session_id(); ?>"},//
file_size_limit : "100 MB",//上传最大容量
file_types : "*.*",//*.jpg
file_types_description : "All Files",
file_upload_limit : 3, //配置上传个数最大值
file_queue_limit : 0,
custom_settings : {//bind submit and cancel
progressTarget : "fsUploadProgress",
cancelButtonId : "btnCancel"
},
debug: false,
// Button settings
button_image_url: "images/hello.png",
button_width: "240",
button_height: "50",
button_placeholder_id: "spanButtonPlaceHolder",
// button_text: '<span class="theFont">浏览</span>',
// button_text_style: ".theFont { font-size: 16; }",
button_text_left_padding: 12,
button_text_top_padding: 3,
file_queued_handler : fileQueued,
file_queue_error_handler : fileQueueError,
file_dialog_complete_handler : fileDialogComplete,
upload_start_handler : uploadStart,
upload_progress_handler : uploadProgress,
upload_error_handler : uploadError,
upload_success_handler : uploadSuccess,
upload_complete_handler : uploadComplete,
queue_complete_handler : queueComplete
};
var swfu = new SWFUpload(settings);
};
</script>
</head>
<body>
<div id="header">
<h1 id="logo"><a href="/">SWFUpload</a></h1>
<div id="version">v2.2.0</div>
</div>
<div id="content">
<form id="form1" action="index.php" method="post" enctype="multipart/form-data">
<p>点击“浏览”按钮,选择您要上传的文档文件后,系统将自动上传并在完成后提示您。</p>
<p>请勿上传包含中文文件名的文件!</p>
<div class="fieldset flash" id="fsUploadProgress">
<span class="legend">快速上传</span>
</div>
<div id="divStatus">0 个文件已上传</div>
<div>
<span id="spanButtonPlaceHolder"></span>
<input id="btnCancel" type="button" value="取消所有上传" onclick="swfu.cancelQueue();" disabled="disabled" style="margin-left: 2px; font-size: 8pt; height: 29px;" />
</div>
</form>
</div>
</body>
</html>
|