WordPress.org

Make WordPress Core

Ticket #9484: 9484.diff

File 9484.diff, 1.5 KB (added by Denis-de-Bernardy, 6 years ago)

fixed patch

  • wp-includes/formatting.php

     
    117117        $pee = $pee . "\n"; // just to make things a little easier, pad the end 
    118118        $pee = preg_replace('|<br />\s*<br />|', "\n\n", $pee); 
    119119        // Space things out a little 
    120         $allblocks = '(?:table|thead|tfoot|caption|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|select|form|map|area|blockquote|address|math|style|input|p|h[1-6]|hr)'; 
     120        $allblocks = '(?:table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|select|form|map|area|blockquote|address|math|style|input|p|h[1-6]|hr)'; 
    121121        $pee = preg_replace('!(<' . $allblocks . '[^>]*>)!', "\n$1", $pee); 
    122122        $pee = preg_replace('!(</' . $allblocks . '>)!', "$1\n\n", $pee); 
    123123        $pee = str_replace(array("\r\n", "\r"), "\n", $pee); // cross-platform newlines 
  • wp-admin/js/editor.dev.js

     
    136136        }, 
    137137 
    138138        wpautop : function(pee) { 
    139                 var blocklist = 'table|thead|tfoot|caption|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|select|form|blockquote|address|math|p|h[1-6]'; 
     139                var blocklist = 'table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|select|form|blockquote|address|math|p|h[1-6]'; 
    140140 
    141141                if ( pee.indexOf('<object') != -1 ) { 
    142142                        pee = pee.replace(/<object[\s\S]+?<\/object>/g, function(a){