- Timestamp:
- 12/10/2024 09:11:35 AM (5 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/html-api/class-wp-html-processor.php
r59500 r59502 304 304 305 305 while ( $context_processor->next_tag() ) { 306 $context_processor->set_bookmark( 'final_node' ); 306 if ( ! $context_processor->is_virtual() ) { 307 $context_processor->set_bookmark( 'final_node' ); 308 } 307 309 } 308 310 … … 5674 5676 * HTML structure or unwanted processing overhead. 5675 5677 * 5678 * Bookmarks cannot be set on tokens that do no appear in the original 5679 * HTML text. For example, the HTML `<table><td>` stops at tags `TABLE`, 5680 * `TBODY`, `TR`, and `TD`. The `TBODY` and `TR` tags do not appear in 5681 * the original HTML and cannot be used as bookmarks. 5682 * 5676 5683 * @since 6.4.0 5677 5684 * … … 5680 5687 */ 5681 5688 public function set_bookmark( $bookmark_name ): bool { 5689 if ( $this->is_virtual() ) { 5690 _doing_it_wrong( 5691 __METHOD__, 5692 __( 'Cannot set bookmarks on tokens that do no appear in the original HTML text.' ), 5693 '6.8.0' 5694 ); 5695 return false; 5696 } 5682 5697 return parent::set_bookmark( "_{$bookmark_name}" ); 5683 5698 }
Note: See TracChangeset
for help on using the changeset viewer.