Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gutenberg produce BROKEN html output #12953

Closed
EldarAgalarov opened this issue Dec 17, 2018 · 9 comments
Closed

Gutenberg produce BROKEN html output #12953

EldarAgalarov opened this issue Dec 17, 2018 · 9 comments
Labels
Needs Testing Needs further testing to be confirmed. [Type] Help Request Help with setup, implementation, or "How do I?" questions.

Comments

@EldarAgalarov
Copy link

EldarAgalarov commented Dec 17, 2018

How text looks in gutenberg editor:

https://i.imgur.com/ppbPMg7.png

ppbpmg7

How output result looks:
https://i.imgur.com/YO3NGYT.png

yo3ngyt

Part of the text are gone
closing "strong" tag also is gone, producing WRONG html markup

Please fix it.

Wordpress 5.0.1

@designsimply designsimply added [Type] Help Request Help with setup, implementation, or "How do I?" questions. [Block] More Affects the More Block - used for displaying the 'Read More' link [Status] Needs More Info Follow-up required in order to be actionable. and removed [Block] More Affects the More Block - used for displaying the 'Read More' link labels Dec 17, 2018
@EldarAgalarov
Copy link
Author

EldarAgalarov commented Dec 17, 2018

How to reproduce:

Put h2 block with text:
Next put paragraph block below h2 with text:
And what you see on output? only h2 but not paragraph block!

Next, add paragraph block above h2 block with text:
Now last paragraph is shown but it's WRONG - part of words and punctuation are lost! So there are at least 2 bugs!

@designsimply
Copy link
Member

Aha! Thank you for the extra information, I was just about to ask about how this content was first created and to clarify about the screenshots.

I was trying to see in the first screenshots and I noticed this:

screen shot 2018-12-17 at 11 39 08 am

became this:

screen shot 2018-12-17 at 11 40 41 am

And I saw the the ending strong tag was missing for the part of the text that begins with "63.91%".

However, trying with the example text you provided is much better and I will add the Needs Testing tag for that so we can look in more detail.

Can you tell also tell me a little more took to get to this point? Did you write it with Gutenberg directly? Did you write it before upgrading to 5.0.1 and then press the "Convert to Blocks" button? Or did you copy the content from elsewhere such as a word processor or a different post or even another web page?

@designsimply
Copy link
Member

I am not sure yet if it's relevant, but may I also ask if you have any plugins installed which modify content in any way? It's possible to have a plugin conflict, and we should test from our side first without plugins but it's also a good idea to make a note of them if you have any.

@designsimply designsimply added Needs Testing Needs further testing to be confirmed. and removed [Status] Needs More Info Follow-up required in order to be actionable. labels Dec 17, 2018
@EldarAgalarov
Copy link
Author

EldarAgalarov commented Dec 17, 2018

I'm writing in with Gutenberg directly, without content conversion from classic editor into blocks. Just copy-pasting text from Notepad-like text editor.

@EldarAgalarov
Copy link
Author

I disabled all plugins and it not helped. In general i'm using WPML and Yoast SEO now.

@EldarAgalarov
Copy link
Author

I found that if Gutenberg doesn't produce HTML comments like then seems it works fine. HTML comments in some ways broke text output.

@EldarAgalarov
Copy link
Author

This issue related with #13404

@designsimply
Copy link
Member

Thank you so much for the follow-ups! I researched this and found that #13404 was closed as a duplicate of #12672 and there is a request in that issue to re-open the case at https://core.trac.wordpress.org/ and I wanted to leave a note here with the status that I found.

@SergeyBiryukov
Copy link
Member

Tracked this down to an issue with WP_Block_Parser, let's continue the discussion in #13655.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Testing Needs further testing to be confirmed. [Type] Help Request Help with setup, implementation, or "How do I?" questions.
Projects
None yet
Development

No branches or pull requests

3 participants