Add error message when loading the preview image in the image editor fails, fixes #18723

git-svn-id: http://svn.automattic.com/wordpress/trunk@18798 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
azaozz
2011-09-28 06:08:56 +00:00
parent 8c1bc6831a
commit 8315e48d3a
3 changed files with 8 additions and 2 deletions

View File

@@ -181,6 +181,9 @@ imageEdit = {
$('input.imgedit-submit-btn', '#imgedit-panel-' + postid).prop('disabled', true);
t.toggleEditor(postid, 0);
}).error(function(){
$('#imgedit-crop-' + postid).empty().append('<div class="error"><p>' + imageEditL10n.error + '</p></div>');
t.toggleEditor(postid, 0);
}).attr('src', ajaxurl + '?' + $.param(data));
},

File diff suppressed because one or more lines are too long