Ticket #8630: 8630_2.patch

File 8630_2.patch, 877 bytes (added by Alfonso Martínez de Lizarrondo, 7 years ago)

Simple replacement patch

  • _source/plugins/htmldataprocessor/plugin.js

     
    516516                        // Call the browser to help us fixing a possibly invalid HTML
    517517                        // structure.
    518518                        var div = new CKEDITOR.dom.element( 'div' );
     519
     520                        // Prevent execution of event handlers in the div (#8630)
     521                        data = data.replace( /\bon/g, ' data-ckeoff' );
     522
    519523                        // Add fake character to workaround IE comments bug. (#3801)
    520524                        div.setHtml( 'a' + data );
    521525                        data = div.getHtml().substr( 1 );
    522526
     527                        // Restore event handlers (#8630)
     528                        data = data.replace( / data-ckeoff/g, ' on' );
     529
    523530                        // Unprotect "some" of the protected elements at this point.
    524531                        data = unprotectElementNames( data );
    525532
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy