WordPress.org

Make WordPress Core

Opened 2 years ago

Closed 7 months ago

#47347 closed defect (bug) (duplicate)

HTML error with the multi-level list in Classic Editor

Reported by: sasiddiqui Owned by:
Milestone: Priority: normal
Severity: normal Version: 5.2
Component: Editor Keywords:
Focuses: Cc:

Description

I have recently created a multi-level list which is throwing HTML validation error:

No p element in scope but a p end tag seen.

This error appears when there is some text between the multi-level list as shown here:

As you see that in Item 1 there is a text and then an unordered list. In this case, extra closing p tag is found in HTML but if the text is removed or the list gets removed then there will be no HTML validation error.

Here is an example link I have created with fresh WordPress install with Twenty Nineteen theme and the Classic Editor plugin.

With Gutenberg: https://dev-site-validation.pantheonsite.io/2019/05/22/testing-multi-level-list-with-gutenberg/

Without Gutenberg: https://dev-site-validation.pantheonsite.io/2019/05/22/testing-multi-level-list-without-gutenberg/

There is no other plugin installed at this time.

Attachments (1)

Screen Shot 2019-05-22 at 4.26.01 PM.png (127.5 KB) - added by sasiddiqui 2 years ago.
showing backend of content

Download all attachments as: .zip

Change History (11)

@sasiddiqui
2 years ago

showing backend of content

#1 @afercia
2 years ago

  • Component changed from General to Editor

This ticket was mentioned in Slack in #core by desrosj. View the logs.


2 years ago

#3 @antpb
2 years ago

  • Keywords reporter-feedback added

@sasiddiqui thanks so much for this report and also including a handy demo! Can you please share a copy of the raw Gutenberg markup and raw Classic Editor markup for this? I want to make sure that I am testing against the same post data that you have. I've structured a post similarly in Classic Editor and Gutenberg using a soft return between list_item_1 with the desired text between the next level list item successfully without extra markup. Maybe I am misunderstanding the reproduction steps. :)

#4 @sasiddiqui
2 years ago

@antpb Here is the copy of what I have tried.
https://docs.google.com/document/d/1aKul8HdbiNUWBULpxrXjb0PHCQKL71FIPpU1xprBM7s/edit?usp=sharing

NOTE: If you copy and paste this directly from the Document then it will create the HTML error or you may add the text directly in the editor as well.

#5 @sasiddiqui
2 years ago

  • Keywords needs-testing added; reporter-feedback removed

Is there any update on it? Does anyone able to produce this issue?

#6 @yasglobal
2 years ago

  • Keywords reporter-feedback added; needs-testing removed

I am also facing this issue. I am testing this with Classic Editor on the latest version of WordPress 5.2.2

#7 @noisysocks
7 months ago

Hi @sasiddiqui. Where do you see the HTML validation error? I can't see your screenshots in the ticket description.

#8 @sasiddiqui
7 months ago

@noisysocks Here is the direct URL of the screenshot:
https://core.trac.wordpress.org/attachment/ticket/47347/Screen%20Shot%202019-05-22%20at%204.26.01%20PM.png

Here is the copy of what I have tried.
https://docs.google.com/document/d/1aKul8HdbiNUWBULpxrXjb0PHCQKL71FIPpU1xprBM7s/edit?usp=sharing

NOTE: If you copy and paste this directly from the Document then it will create the HTML error or you may add the text directly in the editor as well.

#9 @sasiddiqui
7 months ago

  • Keywords reporter-feedback removed

#10 @noisysocks
7 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Thanks @sasiddiqui. I see the error now. Closing this as it's the same root cause as #27350.

Note: See TracTickets for help on using tickets.