Blueimp의 jQuery 파일 업로드 플러그인을 사용하고 있으며 작동하지 못했습니다. 나는 이것을 site에 사용하고 있습니다. 파일을 추가 할 수있는 것 같지만 '업로드 시작'을 클릭하면 '오류, 초과 할당량 :이 애플리케이션은 일시적으로 게재 할당량을 초과했습니다. 나중에 다시 시도하십시오'라는 메시지가 나타납니다. 이걸 본 사람 있어요?Blueimp jQuery 파일 업로드 플러그인 - '업로드 시작'을 클릭하면 할당량 초과 오류가 발생했습니다.
<form id="fileupload" action="//grk.co/test2/" method="POST" enctype="multipart/form-data">
<!-- Redirect browsers with JavaScript disabled to the origin page -->
<noscript><input type="hidden" name="redirect" value="http://grk.co/test2/"></noscript>
<!-- The fileupload-buttonbar contains buttons to add/delete files and start/cancel the upload -->
<div class="row fileupload-buttonbar">
<div class="col-lg-7">
<!-- The fileinput-button span is used to style the file input field as button -->
<span class="btn btn-success fileinput-button">
<i class="glyphicon glyphicon-plus"></i>
<span>Add files...</span>
<input type="file" name="files[]" multiple>
</span>
<button type="submit" class="tiny success start">
<i class="glyphicon glyphicon-upload"></i>
<span>Start upload</span>
</button>
<button type="reset" class="tiny secondary cancel">
<i class="glyphicon glyphicon-ban-circle"></i>
<span>Cancel upload</span>
</button>
<button type="button" class="tiny alert delete">
<i class="glyphicon glyphicon-trash"></i>
<span>Delete</span>
</button>
<input type="checkbox" class="toggle">
<!-- The loading indicator is shown during file processing -->
<span class="fileupload-loading"></span>
</div>
<!-- The global progress information -->
<div class="col-lg-5 fileupload-progress fade">
<!-- The global progress bar -->
<div class="progress progress-striped active" role="progressbar" aria-valuemin="0" aria-valuemax="100">
<div class="progress-bar progress-bar-success" style="width:0%;"></div>
</div>
<!-- The extended global progress information -->
<div class="progress-extended"> </div>
</div>
</div>
<!-- The table listing the files available for upload/download -->
<table role="presentation" class="table table-striped"><tbody class="files"></tbody></table>
</form>
그리고 내 JS : 사람이 아무 잘못을 발견 할 수있는 경우
<script>
/*jslint unparam: true */
/*global window, $ */
$(function() {
'use strict';
// Change this to the location of your server-side upload handler:
var url = window.location.hostname === '91.208.99.4' ?
'//grk.co/test2/' : 'server/php/';
$('#fileupload').fileupload({
url: url,
dataType: 'json',
done: function (e, data) {
$.each(data.result.files, function (index, file) {
$('<p/>').text(file.name).appendTo('#files');
});
},
progressall: function (e, data) {
var progress = parseInt(data.loaded/data.total * 100, 10);
$('#progress .progress-bar').css(
'width',
progress + '%'
);
}
}).prop('disabled', !$.support.fileInput)
.parent().addClass($.support.fileInput ? undefined : 'disabled');
});
</script>
, 나는 그것을 대단히 감사하겠습니다
여기 내 HTML입니다. 나는 jQuery로 새로운 것이므로 뭔가를 놓친다.
더 많은 정보가 필요하면 알려 주시기 바랍니다.
URL을 업데이트하지만 초과 할당량 페이지로 이동하는 대신 index.html로 리디렉션됩니다. 대신 어떤 URL을 사용해야하는지 잘 모르겠습니다. 분명히 내가하는 일을 모른다. 누군가 제발 도와 줘? –