Ticket #4719: 4719_3.patch

File 4719_3.patch, 1.8 KB (added by Minh Nguyen, 14 years ago)
  • _source/core/htmlparser/basicwriter.js

     
    6060                 */
    6161                attribute : function( attName, attValue )
    6262                {
    63                         // Browsers don't always escape quote in attribute values. (#4683)
    64                         attValue = attValue.replace( /"/g, '"' )
     63                        if ( CKEDITOR.env.ie )
     64                                attValue = CKEDITOR.tools.htmlEncode( attValue );
    6565
    6666                        this._.output.push( ' ', attName, '="', attValue, '"' );
    6767                },
  • _source/core/tools.js

     
    316316                                        return fix2( text ).replace( / /g, ' ' );
    317317                                } :
    318318                                fix2;
     319                               
     320                        var fix4 = ( standard( '"' ) == '"') ?
     321                                function( text )
     322                                {
     323                                        // Browsers don't always escape quote in attribute values #4683, #4719.
     324                                        return fix3( text ).replace(/"/g, '"');
     325                                } :
     326                                fix3;
     327                               
     328                        this.htmlEncode = fix4;
    319329
    320                         this.htmlEncode = fix3;
    321 
    322330                        return this.htmlEncode( text );
    323331                },
    324332
  • _source/plugins/htmlwriter/plugin.js

     
    173173                {
    174174                        if ( this.forceSimpleAmpersand )
    175175                                attValue = attValue.replace( /&/, '&' );
     176                        if ( CKEDITOR.env.ie )
     177                                attValue = CKEDITOR.tools.htmlEncode( attValue );
    176178
    177                         // Browsers don't always escape quote in attribute values. (#4683)
    178                         attValue = attValue.replace( /"/g, '"' )
    179 
    180179                        this._.output.push( ' ', attName, '="', attValue, '"' );
    181180                },
    182181
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy