[wp-trac] [WordPress Trac] #40676: wpautop adds opening & closing p tags around the opening a tag and around the closing a tag when the link contains certain flow content elements like div, h1, h2...

WordPress Trac noreply at wordpress.org
Wed Jul 19 18:26:05 UTC 2017


#40676: wpautop adds opening & closing p tags around the opening a tag and around
the closing a tag when the link contains certain flow content elements like
div, h1, h2...
-------------------------------------------------+-------------------------
 Reporter:  diegocanal                           |       Owner:
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
Component:  Formatting                           |  Review
 Severity:  normal                               |     Version:
 Keywords:  needs-patch needs-unit-tests 2nd-    |  Resolution:
  opinion                                        |     Focuses:
-------------------------------------------------+-------------------------
Changes (by afercia):

 * keywords:  needs-patch needs-unit-tests => needs-patch needs-unit-tests
     2nd-opinion
 * version:  4.7.4 =>


Comment:

 Worth noting
 `<a href="https://example.com/"><div>DIV inside link</div></a>`
 is valid in HTML5. However, WordPress shouldn't assume all the themes use
 HTML5 as this would be invalid in HTML 4.0.1.

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


More information about the wp-trac mailing list