我有一些代码。它有效......然后我在顶部添加了一个 php httpS(安全)标头重定向。再次刷新代码,现在它失败了。它只是不接受任何文件作为拖放。我可以清除缓存、清除 cookie 做任何我想做的事情……它不再起作用了。
我必须用注释掉的行重新启动 chrome,然后它才能再次工作。为什么 ?
<?php
//header( "Location: ". 'https://127.0.0.1/blank.htm' );die; /* uncomment this line to make it fail */
// it MUST be a "secure" redirect to make it fail
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>blah</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="TestAuditor testing quality management">
<meta name="author" content="The TestAuditor Team">
<link href="CSS/dropzone.css" rel="stylesheet">
</head>
<body>
<div class="span6">
<div id="dropzone" class="fade well ui-corner-all">Drop files here</div>
</div>
<script src="JS/jquery-1.9.0.js"></script>
<script src="JS/jquery.filedrop.js"></script>
<script type="text/javascript">
//-----------------------
$(document).ready(function ()
{
$('#dropzone').show().filedrop(
{
fallback_id: '',
url: 'AnyUploadFileManager.php',
paramname: 'userfile',
withCredentials: true,
allowedfiletypes: [],
maxfiles: 250,
maxfilesize: 20,
drop: function() { },
uploadFinished: function(i, file, response, time) {alert('done'); },
beforeSend: function(file, i, done) {done(); }
});
});
//-----------------------
</script>
</body>
</html>