나는이 문제가 무엇인지 잘 모릅니다. 나는 인스턴스를 uploadify로 대체하는 2 개의 placeholder 엘리먼트를 가지고있다. 2 자리 표시 자 html 요소는 정확히 동일하며 정확히 동일한 업로드 코드 (jquery. each로 두 자리 표시자를 반복 함)로 바뀝니다. 유일한 차이점은 ID가 다른 것입니다.Uploadify가 'queueData'속성을 읽을 수 없습니다.
그들 중 하나는 완전히 작동하지만 다른 하나는 'undefined 속성 queueData를 읽을 수 없습니다'예외를 throw합니다. 나는 uploadify 코드를 검사했는데 저장해야하는 swfupload를 찾을 수 없기 때문에 이런 일이 발생했습니다. uploadify 내에서 관련 코드는 여기
if (flashInstalled) {
// Create the swfUpload instance
window['uploadify_' + settings.id] = new SWFUpload(swfUploadSettings);
var swfuploadify = window['uploadify_' + settings.id];
// Add the SWFUpload object to the elements data object
$this.data('uploadify', swfuploadify);
하고는 $ this.data
// Start uploading files in the queue
upload : function() {
var args = arguments;
this.each(function() {
// Create a reference to the jQuery DOM object
var $this = $(this),
swfuploadify = $this.data('uploadify');
// Reset the queue information
swfuploadify.queueData.averageSpeed = 0;
swfuploadify.queueData.uploadSize = 0;
swfuploadify에서 검색하려고하는 부분은 '정의되지 않은'으로 변합니다. 나는이 일이 벌어지면서 디버깅을했고, 그 데이터를 확실히 설정 한 첫 번째 줄은 두 번째 부분이 일어날 때까지 정의되지 않았습니다. 나는 이것을 전혀 이해하지 못한다.
Omg, 온라인으로 검색 한 후 이것이 해결책이었습니다. 감사! – Refilon