[Resolved] "This block contains unexpected or invalid content"

Home Forums Support "This block contains unexpected or invalid content"

  • This topic has 5 replies, 2 voices, and was last updated 5 months ago by David.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1147167
    Michael

    Hello all,

    Can anyone explain to me how to resolve an error I am getting in the pages editor whereby the blocks have a message that says “This block contains unexpected or invalid content”. As far as I am aware the code is fine and is not invalid. I have tried pressing the Resolve button and also the Convert to HTML button to see what they do, but they didn’t seem to help. The blocks are “custom HTML” blocks in the first instance, so am not sure why it would ask to convert anyway?

    https://www.dropbox.com/s/bqez58g3msm6cxv/invalid-content.jpg?dl=0

    Thanks very much!

    Michael.

    #1147279
    David
    Staff
    Customer Support

    Hi there,

    i think the Gutenberg block validator can be a bit hit and miss.
    Any error / warning / log in the Developers Console ?

    #1147370
    Michael

    Hi David,

    Thanks for getting back to me. Indeed there is. I didn’t think to look at that:

    Block validation: Expected tag name tbody, instead saw tr.

    I am using tables with this format:

    <table class="header">
        <tr>
            <td class="center">
                <header>
                    <h1>The Story and Ethos Behind Reclaim Design</h1>
                </header>
            </td>
        </tr>
    </table>

    I didn’t realize it was necessary to include tbody?

    #1147401
    David
    Staff
    Customer Support

    I think WP’s HTML is just super hard assed about everything – and that definitely proves it lol

    #1147498
    Michael

    OK, thanks very much David for your help. I’m on a bit of learning curve with WP!

    #1147609
    David
    Staff
    Customer Support
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.