[wp-trac] [WordPress Trac] #37672: wpautop adds a closing p-tag without an opening p-tag
WordPress Trac
noreply at wordpress.org
Mon Aug 15 19:06:04 UTC 2016
#37672: wpautop adds a closing p-tag without an opening p-tag
--------------------------+-----------------------------
Reporter: TBarregren | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Formatting | Version: 4.5.3
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
Following code result in ill-formed HTML.
{{{#!php
<?php
$pee = <<<EOT
<div>
This is a paragraph.
This is another paragraph.
</div>
EOT;
echo wpautop($pee);
}}}
This is the output:
{{{
<div>
This is a paragraph.</p>
<p>This is another paragraph.
</p></div>
}}}
As you can see, the first paragraph lacks an opening <p>.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/37672>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list