WordPress.org

Make WordPress Core

Opened 4 years ago

Last modified 3 months ago

#15006 reopened defect (bug)

Invalid Content Markup — at Version 6

Reported by: miqrogroove Owned by:
Milestone: Future Release Priority: normal
Severity: minor Version: 3.0
Component: Formatting Keywords: needs-patch wpautop needs-unit-tests
Focuses: Cc:

Description (last modified by dd32)

I have a page post that starts like this:

<p style="text-align: right;">Text Here</p>
<p style="text-align: right;"></p>
More Text Here

The HTML source saves correctly, but the page output omits the closing tag for the second P element, causing the rest of the page to be invalid.

If you have any trouble reproducing this I will be happy to debug it on my server.

Change History (6)

comment:1 miqrogroove4 years ago

The workaround I am currently using:

<p style="text-align: right;">Text Here</p>
<p style="text-align: right;">.</p>
More Text Here

Putting any text in the second paragraph somehow fixes the problem.

comment:2 scribu4 years ago

  • Component changed from General to Formatting

Confirmed.

comment:3 scribu4 years ago

  • Severity changed from normal to minor

Why do you need an empty <p> tag anyway?

comment:4 demetris4 years ago

Unsurprisingly perhaps, when I activated PHP Markdown (which automatically disables wpautop and does its own autoparagraphing) the problem disappeared.

comment:5 miqrogroove4 years ago

Why do you need an empty <p> tag anyway?

This ticket is about invalid output. If there's a problem in the html editor you should make a separate ticket for that.

comment:6 dd323 years ago

  • Description modified (diff)
Note: See TracTickets for help on using tickets.