summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
6b81779)
Unobtrusive indication of success.
ajaxpost.onreadystatechange = function () {
if (ajaxpost.readyState != 4)
return; // not done yet
ajaxpost.onreadystatechange = function () {
if (ajaxpost.readyState != 4)
return; // not done yet
- if (ajaxpost.status != 200)
- alert('Foutcode '+ajaxpost.status+' bij opslaan: '+ajaxpost.responseText);
- else
+ if (ajaxpost.status == 200) {
+ new CKEDITOR.plugins.notification(editor, {
+ message: 'Pagina is succesvol opgeslagen',
+ type: 'success',
+ }).show();
+ }
+ else {
+ new CKEDITOR.plugins.notification(editor, {
+ message: 'Foutcode '+ajaxpost.status+' bij opslaan: '+ajaxpost.responseText,
+ type: 'warning',
+ }).show();
+ }
};
ajaxpost.send(data);
},
};
ajaxpost.send(data);
},