火狐浏览器中jquery uploadify 为什么不能上传附件进不去action
IE浏览器可以保存 var filesName='';
var now= new Date();
var year=now.getYear();
var month=now.getMonth()+1;
var day=now.getDate();
var hour=now.getHours();
var minute=now.getMinutes();
var second=now.getSeconds();
var milSecond = now.getMilliseconds();
var divid = year+""+month+""+day+""+hour+""+minute+""+second +""+milSecond ;
function initUploadify(){
$("#uploadFiles").uploadify({
'uploader' : '<%=request.getContextPath() %>/resources/public/js/uploadify/uploadify.swf?temp='+(new Date().getTime()),
'script' : '<%=request.getContextPath() %>/zixun_uploadAttachment.do?datetime='+divid, //这边的跳不进action里面
'cancelImg' : '<%=request.getContextPath() %>/resources/public/images/cancel.png',
'queueID' : 'fileQueue',
'auto' : false,
'fileDataName' : 'uploadFiles',
'folder' : '/',
'multi' : true,
'buttonImg' :'<%=request.getContextPath() %>/resources/public/js/uploadify/anniu.jpg',
'wmode' : 'transparent',
'simUploadLimit' : 999,
onError:function(event, queueID, fileObj){
alert("文件:" + fileObj.name + "上传失败");
},
onComplete:function(event, ID, fileObj, response, data){
var j=eval("(" + response + ")");
if(j.sess){
filesName+=fileObj.name+"<";
}else{
alert("文件:" + fileObj.name + "上传失败");
}
},
onAllComplete:function(event,data){
if(filesName.length>0){
filesName=filesName.substring(0,filesName.length-1);
document.getElementById("filesName").value = filesName;
}
document.getElementById("filepathes").value = divid;
document.getElementById("save").disabled=true;
document.getElementById("sub").disabled=true;
document.getElementById("res").disabled=true;
document.forms[0].submit();
}
});
}
IE浏览器可以保存 var filesName='';
var now= new Date();
var year=now.getYear();
var month=now.getMonth()+1;
var day=now.getDate();
var hour=now.getHours();
var minute=now.getMinutes();
var second=now.getSeconds();
var milSecond = now.getMilliseconds();
var divid = year+""+month+""+day+""+hour+""+minute+""+second +""+milSecond ;
function initUploadify(){
$("#uploadFiles").uploadify({
'uploader' : '<%=request.getContextPath() %>/resources/public/js/uploadify/uploadify.swf?temp='+(new Date().getTime()),
'script' : '<%=request.getContextPath() %>/zixun_uploadAttachment.do?datetime='+divid, //这边的跳不进action里面
'cancelImg' : '<%=request.getContextPath() %>/resources/public/images/cancel.png',
'queueID' : 'fileQueue',
'auto' : false,
'fileDataName' : 'uploadFiles',
'folder' : '/',
'multi' : true,
'buttonImg' :'<%=request.getContextPath() %>/resources/public/js/uploadify/anniu.jpg',
'wmode' : 'transparent',
'simUploadLimit' : 999,
onError:function(event, queueID, fileObj){
alert("文件:" + fileObj.name + "上传失败");
},
onComplete:function(event, ID, fileObj, response, data){
var j=eval("(" + response + ")");
if(j.sess){
filesName+=fileObj.name+"<";
}else{
alert("文件:" + fileObj.name + "上传失败");
}
},
onAllComplete:function(event,data){
if(filesName.length>0){
filesName=filesName.substring(0,filesName.length-1);
document.getElementById("filesName").value = filesName;
}
document.getElementById("filepathes").value = divid;
document.getElementById("save").disabled=true;
document.getElementById("sub").disabled=true;
document.getElementById("res").disabled=true;
document.forms[0].submit();
}
});
}
是没有flash按钮还是什么
上传附件 的时候不进action
'script' : '<%=request.getContextPath() %>/zixun_uploadAttachment.do',
//这边的跳不进action里面
如果是404,那你的路径有问题
不然就看这个action访问的request和response数据