- Timestamp:
- 09/03/2024 07:48:57 PM (15 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/html-api/class-wp-html-processor.php
r58970 r58977 844 844 if ( self::PROCESS_NEXT_NODE === $node_to_process ) { 845 845 parent::next_token(); 846 if ( 847 WP_HTML_Tag_Processor::STATE_TEXT_NODE === $this->parser_state || 848 WP_HTML_Tag_Processor::STATE_CDATA_NODE === $this->parser_state 849 ) { 846 if ( WP_HTML_Tag_Processor::STATE_TEXT_NODE === $this->parser_state ) { 850 847 parent::subdivide_text_appropriately(); 851 848 } … … 4376 4373 4377 4374 switch ( $op ) { 4378 case '#cdata-section':4379 4375 case '#text': 4380 4376 /* … … 4390 4386 */ 4391 4387 if ( parent::TEXT_IS_GENERIC === $this->text_node_classification ) { 4388 $this->state->frameset_ok = false; 4389 } 4390 4391 $this->insert_foreign_element( $this->state->current_token, false ); 4392 return true; 4393 4394 /* 4395 * CDATA sections are alternate wrappers for text content and therefore 4396 * ought to follow the same rules as text nodes. 4397 */ 4398 case '#cdata-section': 4399 /* 4400 * NULL bytes and whitespace do not change the frameset-ok flag. 4401 */ 4402 $current_token = $this->bookmarks[ $this->state->current_token->bookmark_name ]; 4403 $cdata_content_start = $current_token->start + 9; 4404 $cdata_content_length = $current_token->length - 12; 4405 if ( strspn( $this->html, "\0 \t\n\f\r", $cdata_content_start, $cdata_content_length ) !== $cdata_content_length ) { 4392 4406 $this->state->frameset_ok = false; 4393 4407 }
Note: See TracChangeset
for help on using the changeset viewer.