9e0a116dbf
In some cases, it's possible to seek back into a location found inside an element which has been closed before the point in the document where the `seek()` was made. In these cases the breadcrumb stack is lost, and calling `get_breadcrumbs()` after the seek will return the wrong information. In this patch, the HTML Processor takes a conservative approach and moves to the front of the document, then reparses the document until it reaches the sought-after location. This ensures consistency on the stack of open elements and active formats, and preserves breadcrumbs. Developed in https://github.com/WordPress/wordpress-develop/pull/6185 Discussed in https://core.trac.wordpress.org/ticket/60687 Props jonsurrell. Follow-up to [60687]. See #58517. Fixes #60687. Built from https://develop.svn.wordpress.org/trunk@57768 git-svn-id: http://core.svn.wordpress.org/trunk@57269 1a063a9b-81f0-0310-95a4-ce76da25c4cd |
||
---|---|---|
.. | ||
class-wp-html-active-formatting-elements.php | ||
class-wp-html-attribute-token.php | ||
class-wp-html-open-elements.php | ||
class-wp-html-processor-state.php | ||
class-wp-html-processor.php | ||
class-wp-html-span.php | ||
class-wp-html-tag-processor.php | ||
class-wp-html-text-replacement.php | ||
class-wp-html-token.php | ||
class-wp-html-unsupported-exception.php |