Editor: preserve the textarea content when saving, wpautop is not used and TinyMCE is hidden. Props WraithKenny, fixes #23743
git-svn-id: http://core.svn.wordpress.org/trunk@23745 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b09f9fa157
commit
829a6f541b
|
@ -217,12 +217,11 @@
|
|||
});
|
||||
|
||||
ed.onSaveContent.add(function(ed, o) {
|
||||
if ( ed.getParam('wpautop', true) && typeof(switchEditors) == 'object' ) {
|
||||
// If editor is hidden, we just want the textarea's value to be saved
|
||||
if ( ed.isHidden() )
|
||||
o.content = o.element.value;
|
||||
else
|
||||
else if ( ed.getParam('wpautop', true) && typeof(switchEditors) == 'object' )
|
||||
o.content = switchEditors.pre_wpautop(o.content);
|
||||
}
|
||||
});
|
||||
|
||||
/* disable for now
|
||||
|
|
Loading…
Reference in New Issue