Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #837668

    Hi
    Googles test-tool for structured data returns an error for my blogpage.

    main class='content av-content-small alpha units' role="main" itemprop="mainContentOfPage" itemscope="itemscope" itemtype="https://schema.org/Blog" ><article class='post-entry post-entry-type-standard post-entry-13971 post-loop-1 post-parity-odd single-small with-slider post-13971 post type-post status-publish format-standard has-post-thumbnail hentry category-newsfeed' itemscope="itemscope" itemtype="https://schema.org/BlogPosting" itemprop="blogPost" >

    If I delete itemprop=”mainContentOfPage” from that source, the test is positive. How can I solve that? I’m using Enfold 4.0.7.
    Thanks for help
    filz51

    • This topic was modified 7 years, 4 months ago by filz51.
    #839572

    Hey filz51,

    But on the rest pages – and not the blog page, the maincontent works properly, right?

    Best regards,
    Basilis

    #839592

    Hi Basilis

    I didn’t test all the pages but I think you are right. Only the blog page shows this error so far.

    Kind regards, filz51

    #841046

    Hi,

    That is because the pages are created to work on that way and if you need to add the Blog element, you still add that element inside a page, so the way it works is, but the article will generate the proper schema.

    Best regards,
    Basilis

    #842268

    Hi Basilis
    I’d like to add the Blog element inside the blog page. But how can I do this? I tried to add this:

    <div itemscope itemtype="http://schema.org/WebPage">
      <section itemprop="mainEntity" itemscope itemtype="http://schema.org/Blog"></section></div>

    But the error is still there. Please help.
    Regards, filz51

    • This reply was modified 7 years, 4 months ago by filz51.
    #843707

    Hi,

    You cant change the schema with that way.
    You would need to create a child theme, move the page.php file and the create an if statement, with the page ID, that can change the schema based on the page that is hosting the blog element.

    Best regards,
    Basilis

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.