hi
habs jetzt so:
function oncomplete (obj, callback, tries) {
tries--;
window.setTimeout(function () {
if (obj.complete && obj.complete === true) {
callback();
return true;
} else if (tries > 0) {
oncomplete(obj, callback, tries);
} else {
return false;
}
}, 500);
}
$(document).ready(function () {
oncomplete ($('#bild').get(0), function (event) {
window.alert('bild geladen');
}, 10);
});
Scheint zu funktionieren.