[wp-trac] [WordPress Trac] #61581: HTML Processor should respect `tag_name` argument in `next_tag()`

WordPress Trac noreply at wordpress.org
Sat Jul 6 10:18:18 UTC 2024


#61581: HTML Processor should respect `tag_name` argument in `next_tag()`
--------------------------+----------------------
 Reporter:  dmsnell       |       Owner:  dmsnell
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  6.7
Component:  HTML API      |     Version:  6.4
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |     Focuses:
--------------------------+----------------------
Changes (by dmsnell):

 * owner:  (none) => dmsnell
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"58681" 58681]:
 {{{
 #!CommitTicketReference repository="" revision="58681"
 HTML API: Respect `tag_name` query arg in `HTML_Processor::next_tag()`

 Previously the HTML Processor was ignoring the `tag_name` argument in
 the `next_tag()` query if it existed. This was wrong adn would lead to
 calling code finding the very next tag, regardless of tag name, instead
 of the requested taag.

 This patch adds the tag name detection code into `next_tag()` to fix
 the bug and ensure that `next_tag()` always returns only when finding
 a tag of the given name.

 Developed in https://github.com/WordPress/wordpress-develop/pull/6980
 Discussed in https://core.trac.wordpress.org/ticket/61581

 Follow-up to [56274].

 Fixes #61581.
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/61581#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list