• Resolved frenchomatic

    (@frenchomatic)


    I have put this on github but wanted to know if others are seeing the same issue. If the site has no blog posts page or blogs then some of the structured data on the static home page is NULL.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Ahmed Kaludi

    (@ahmedkaludi)

    Sure, Looking forward to hear from more people.

    This has never been right.
    This is a site that has a “Blog” category and a staic page for the Homepage.

    It is the reason (still) why I have never deployed AMP for WP on money sites.

    https://singleserve.net.au/
    <title>Single Serve Louise Harper – Cooking for One</title>
    <meta name=”description” content=”The Single Serve series is a collection of books, recipes and tips for the single person wanting to just cook for one.” />

    https://singleserve.net.au/amp/
    <title>Single Serve – Cooking for One | Delicious meals for one in under 20 minutes.</title>
    <meta name=”description” content=”While you are baking those potatoes I wrote about in my Lamb with Red Beet Sauce post, take five minutes to whip up this dessert and bake it with them.” />

    Thread Starter frenchomatic

    (@frenchomatic)

    I coded around it on version 9.5.9 to overcome the problem for my needs (client sites) – I really am hoping that the 3 wordpress scenarios are going to produce the correct structured data for their respective pages in the next release.

    static home page + blog posts page
    static home page only
    blog posts page

    I have put the problem on github in different posts as the problem became clearer.

    The problem occurs because although structured data is set correctly for blog posts page, only part gets set for a static home page. What then happens is structured data from the blog posts page gets injected into the static home page. So it looks correct but actually it isn’t.

    You only get to really see the problem if you have no blog posts page at all then the static home page misses having structured data for headline, person …

    So basically you can overcome it with a bit of coding and a fudge in how you set up admin.

    I believe the plugin team are now looking at this for the next release.

    • This reply was modified 7 years, 4 months ago by frenchomatic.
    Plugin Author Ahmed Kaludi

    (@ahmedkaludi)

    Hi @frenchomatic

    After spending few mins, I couldn’t find a ticket,

    Can you confirm if this was fixed or if there is a ticket that you can point me towards?

    Thread Starter frenchomatic

    (@frenchomatic)

    No it is not fixed but it looks like Marqas is on it. It has been put on github several times since 9.5.9 – the latest ticket is this #1260

    I do think the issue is now clearer and why it happens. There are 3 scenarios in WordPress

    1. Static home only
    2. Static home page + blog posts page
    3. Just a blog posts page

    The issue is the structured data for a static home page is incorrect because it is never set correctly. Instead it will either miss data (be invalid under case 1) or will take on the data of the blog posts page in scenario 2 (what the other other user is also saying). If you look at this function ampforwp_search_or_homepage_or_staticpage_metadata, it is not testing for a static home page – it only tests for if archive in it and that is the problem.

    Plugin Author Ahmed Kaludi

    (@ahmedkaludi)

    @frenchomatic
    Sure, Thanks for giving the ticket reference, I will make sure we act on it ASAP.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Structured data issue’ is closed to new replies.