Make WordPress Core

Changeset 31186


Ignore:
Timestamp:
01/16/2015 12:26:36 AM (10 years ago)
Author:
wonderboymusic
Message:

Ensure that <figcaption> is not autop'd.

Fixes #29219.

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/js/editor.js

    r29815 r31186  
    212212            blocklist = 'table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre' +
    213213                '|form|map|area|blockquote|address|math|style|p|h[1-6]|hr|fieldset|legend|section' +
    214                 '|article|aside|hgroup|header|footer|nav|figure|details|menu|summary';
     214                '|article|aside|hgroup|header|footer|nav|figure|figcaption|details|menu|summary';
    215215
    216216        if ( pee.indexOf( '<object' ) !== -1 ) {
  • trunk/src/wp-includes/formatting.php

    r31127 r31186  
    406406    $pee = preg_replace('|<br />\s*<br />|', "\n\n", $pee);
    407407    // Space things out a little
    408     $allblocks = '(?:table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|form|map|area|blockquote|address|math|style|p|h[1-6]|hr|fieldset|legend|section|article|aside|hgroup|header|footer|nav|figure|details|menu|summary)';
     408    $allblocks = '(?:table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|form|map|area|blockquote|address|math|style|p|h[1-6]|hr|fieldset|legend|section|article|aside|hgroup|header|footer|nav|figure|figcaption|details|menu|summary)';
    409409    $pee = preg_replace('!(<' . $allblocks . '[^>]*>)!', "\n$1", $pee);
    410410    $pee = preg_replace('!(</' . $allblocks . '>)!', "$1\n\n", $pee);
Note: See TracChangeset for help on using the changeset viewer.