[Support request] FAQ Schema not working

Home Forums Support [Support request] FAQ Schema not working

Home Forums Support FAQ Schema not working

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #1619879
    Victor

    I am not being able to implement FAQ Schema in GP:
    – I followed all the instructions on https://docs.generatepress.com/article/hooks-element-overview/
    – I have inserted JSON-LD Code with a HOOK element in wp_footer and ticked “Execute PHP”
    – I tried in generate_before_footer as well with the same result
    – I have set Display rules for the page I wanted to implement
    – Questions/Answers inserted in the JSON-LD code are exactly the same as questions/answers on the page.

    Google Tool (https://search.google.com/test/rich-results) keeps telling me “Page not eligible for rich results known by this test”.
    Could you please tell me what could be going wrong?
    Thanks for your support!

    #1620192
    David
    Staff
    Customer Support

    Hi there,

    did you try the wp_head hook ?

    #1620244
    Victor

    Just tried! Same result.

    #1620467
    Leo
    Staff
    Customer Support

    Couple of things:

    – Did you clear your caching plugins or SG optimizer after adding the code?

    – Is there any instructions on how this schema should be implemented?

    #1620710
    Marty

    Victor, I’ve been using FAQ schema for a while now in GP and have never had an issue as long as it’s validated. I’m using the SOGO Add Script Header Footer plugin which allows adding it to the header easily, so that’s another option you can use.

    Are you validating it in the Rich Results Test tool? Invalid schema won’t display.

    #1620749
    Leo
    Staff
    Customer Support
    #1622240
    Victor

    Marty, Thanks for your answer. I really appreciate it.

    Nevertheless, whenever I have the possibility to use a function from GPP, Generate Blocks, or WP Show Post Pro, I prefer not to install any additional plugin. The combination of that theme with those 2 plugins is amazing! You can do a lot of things! So I try to avoid unnecessary installation of additional plugins.

    The Plugin you mentioned is for “adding scripts to each page/post, etc”. I should definitely be able to do it with Elements Module from GPP.
    If I cannot do it through Elements Module, then something is not working. That is why I was asking.

    As I mentioned above I am trying to validate it with Google Tool (https://search.google.com/test/rich-results) keeps telling me “Page not eligible for rich results known by this test”.

    #1622916
    Leo
    Staff
    Customer Support

    Hi Victor,

    Can you answer my 2 questions here?
    https://generatepress.com/forums/topic/faq-schema-not-working/#post-1620467

    If I cannot do it through Elements Module, then something is not working. That is why I was asking.

    The theme is simply not capable of stopping the code from working if it’s added with the correct method.

    #1622930
    Marty

    As I mentioned above I am trying to validate it with Google Tool (https://search.google.com/test/rich-results) keeps telling me “Page not eligible for rich results known by this test”.

    You need to verify that your schema is valid; you’ve got too many variables because if you’re not sure the schema is even correct, how you can you tell if you have GP set up correctly to use it?

    As I was emphasizing earlier, you need to check that it’s valid. Copy & paste it in the Code section of the Rich Results tool. If it’s not valid it won’t be used by Google. If you know it’s valid you can figure out the rest as far as implementation as they’re assisting you with.

    I always validate my schema code before adding it to a post, as it only takes a single unsupported character or mistyped character to render it invalid. Those markup lines/errors will be flagged so that you can troubleshoot it.

    #2113637
    renaissance868

    Has the adding the schema via Elements=>Hook option ever worked?

    #2113804
    Elvin
    Staff
    Customer Support

    Hi @renaissance868,

    Has the adding the schema via Elements=>Hook option ever worked?

    @Marty’s point here stands. If the schema is valid, it wouldn’t matter how it was added in as long as is added to the correct place.

    Adding it through Elements > Hook element is the same as adding it manually through PHP code snippet add_action().

    A wise man once said:
    "Have you cleared your cache?"

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