Ticket #9774: bodywrap.patch

File bodywrap.patch, 1.2 KB (added by ElMoonLite, 11 years ago)

unified diff of _source/plugins/wysiwygarea/plugin.js (v3.6.2)

  • _source/plugins/wysiwygarea/

    old new  
    996996                                                                                '<body' + ( config.bodyId ? ' id="' + config.bodyId + '"' : '' ) +
    997997                                                                                                  ( config.bodyClass ? ' class="' + config.bodyClass + '"' : '' ) +
    998998                                                                                                  '>' +
     999                                                                                        (config.bodyPrepend ? '<!--BODYPREPENDBEGIN-->' + config.bodyPrepend + '<!--BODYPREPENDEND-->' : '') +
    9991000                                                                                        data +
     1001                                                                                        (config.bodyAppend ? '<!--BODYAPPENDBEGIN-->' + config.bodyAppend + '<!--BODYAPPENDEND-->' : '') +
    10001002                                                                                '</html>';
    10011003                                                                }
    10021004
     
    10231025                                                                var data = fullPage
    10241026                                                                        ? doc.getDocumentElement().getOuterHtml()
    10251027                                                                        : doc.getBody().getHtml();
     1028                                                               
     1029                                                                if( ! fullPage && config.bodyPrepend){
     1030                                                                        data = data.replace(/<!--BODYPREPENDBEGIN-->[\s\S]*<!--BODYPREPENDEND-->/,'');
     1031                                                                }
     1032                                                                if( ! fullPage && config.bodyAppend){
     1033                                                                        data = data.replace(/<!--BODYAPPENDBEGIN-->[\s\S]*<!--BODYAPPENDEND-->/,'');
     1034                                                                }
    10261035
    10271036                                                                // BR at the end of document is bogus node for Mozilla. (#5293).
    10281037                                                                if ( CKEDITOR.env.gecko )
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy