uploadify+PHPExcel无刷新导入数据-完善中1
跳至
[1]
[全屏预览]
<!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>小雨在线-视频上传插件</title> <script src="//cdn.bootcss.com/jquery/1.7.1/jquery.min.js"></script> <script src="jquery.uploadify.min.js" type="text/javascript"></script> <link rel="stylesheet" type="text/css" href="uploadify.css"> </head> <body> <script type="text/javascript"> $(function () { $('#studata').uploadify({ 'auto': false, 'formData': { 'stuid': '1111111111', }, 'buttonText': '请选择上传文件', 'fileSizeLimit': '100MB', 'fileTypeDesc': 'excel文件', 'fileObjName': "studata", 'fileTypeExts': '*.xlsx',//文件类型过滤 'swf': 'uploadify.swf', 'multi': false, 'successTimeout': 1800, 'queueSizeLimit': 100, 'uploader': 'uploadify.php', 'onUploadStart': function (file) { //alert('Starting to upload ' + file.name); //正在上传中... // $('#alert-content').html('正在上传文件'); // modal.modal(); }, //onUploadSuccess为上传完视频之后回调的方法, 'onUploadSuccess': function (file, data, response) { //$('#alert-content').html('正在导入数据'); data = eval("(" + data + ")"); $.ajax({ type: 'POST', url: '../reader.php', dataType: 'html', data: {'exceldir': data.updir}, success: function (retdata) { alert(retdata); //modal.modal('close'); // if(retdata==1){ // alert('导入成功'); // }else{ // alert('导入失败'); // } } }); } }); }); </script> <p><input type="file" value="studata" id="studata"> <input type="button" onclick="javascript:$('#studata').uploadify('upload','*')" value="上传"></p> </body> </html>
Copy after login
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article
Assassin's Creed Shadows: Seashell Riddle Solution
3 weeks ago
By DDD
What's New in Windows 11 KB5054979 & How to Fix Update Issues
2 weeks ago
By DDD
Where to find the Crane Control Keycard in Atomfall
3 weeks ago
By DDD
Saving in R.E.P.O. Explained (And Save Files)
1 months ago
By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics
CakePHP Tutorial
1385
52

