Funkcja w której wywala ten błąd:
function addNewPhoto() { var num_img = $('input[name="photos[]"]').size() + $("a.delete").size(); var id = 'p-' + photoIndex++; var i = ce('input'); i.setAttribute('type', 'file'); i.setAttribute('name', 'photos[]'); var a = ce('a'); a.style.fontSize = 'x-small'; a.style.paddingLeft = '10px'; a.setAttribute('href', '#'); a.setAttribute('divid', id); a.onclick = function() { re(this.getAttribute('divid')); return false; } a.appendChild(document.createTextNode('Remove')); var d = ce('div'); d.setAttribute('id', id); d.setAttribute('style','padding: 4px 0;') d.appendChild(i); d.appendChild(a); gebi('photos').appendChild(d); $('#addPhotoLink').addClass('hide_box'); } } else { alert('Sorry, you have reached the maximum number of images per listing'); } }
Czego to wina jak to naprawić ?