Ticket #3609: 3609.patch
File 3609.patch, 1.9 KB (added by , 16 years ago) |
---|
-
_source/core/htmlparser/fragment.js
107 107 108 108 // Create a <p> in the fragment. 109 109 currentNode = target; 110 parser.onTagOpen( 'p', {} ); 110 // Use P as default, when fixForBody unspecified. 111 parser.onTagOpen( !! fixForBody == fixForBody ? 'p' : fixForBody, {} ); 111 112 112 113 // The new target now is the <p>. 113 114 target = currentNode; … … 284 285 checkPending(); 285 286 286 287 if ( fixForBody && !currentNode.type ) 287 this.onTagOpen( 'p', {} ); 288 // Use P as default, when fixForBody unspecified. 289 this.onTagOpen( !! fixForBody == fixForBody ? 'p' : fixForBody, {} ); 288 290 289 291 currentNode.add( new CKEDITOR.htmlParser.text( text ) ); 290 292 }; … … 311 313 if ( fixForBody && !parent.type && !CKEDITOR.dtd.$body[ node.name ] ) 312 314 { 313 315 currentNode = parent; 314 parser.onTagOpen( 'p', {} ); 316 // Use P as default, when fixForBody unspecified. 317 parser.onTagOpen( !! fixForBody == fixForBody ? 'p' : fixForBody, {} ); 315 318 parent = currentNode; 316 319 } 317 320 -
_source/plugins/wysiwygarea/plugin.js
404 404 405 405 // Get the HTML version of the data. 406 406 if ( editor.dataProcessor ) 407 data = editor.dataProcessor.toHtml( data, ( editor.config.enterMode != CKEDITOR.ENTER_BR ) ); 407 { 408 var fixForBody = ( editor.config.enterMode != CKEDITOR.ENTER_BR ) 409 ? editor.config.enterMode == CKEDITOR.ENTER_DIV ? 'div' : 'p' : false; 410 data = editor.dataProcessor.toHtml( data, fixForBody ); 411 } 408 412 409 413 data = 410 414 editor.config.docType +