Include post content in shortcodes in Rank Math analysis

#644498
  • Resolved Bernd Kaiser
    Rank Math free

    Dear Rank Math team,

    The content of my posts is rendered via shortcodes. That content is not considered by the Rank Math plugin. How can I fix that?

    This section talks about exactly what I need: https://rankmath.com/kb/titles-and-meta/#posts-custom-fields. Adding the names of my custom fields on that config page does not solve the problem, though. The content in these fields is still not considered. I tried both adding only the names of the fields and using the %customfield(field_name)% syntax.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hello,

    Thank you for contacting Rank Math and bringing your concern to our attention. I’m sorry for any inconvenience this issue may have caused you.

    Could you please confirm if you’re using the ACF plugin or if the custom field is coming from another plugin/theme on your site?

    Meanwhile, Rank Math can read the text within the ACF field. If you’re using a shortcode within the ACF field, Rank Math will not be able to read the content inside the shortcode.

    The ACF module is built-in with our plugin and when you enable it, it allows Rank Math to read and analyze your website’s content added using custom fields. You can follow our guide to activate ACF compatibility: https://rankmath.com/kb/advanced-custom-fields/

    Looking forward to helping you.

    Thank you.

    Hi Reinelle,

    Thanks for looking into this!

    I don’t use ACF. I define the custom fields in a plugin that I developed.

    Hello,

    Thank you for your patience.

    At the moment, Rank Math can read WordPress custom fields that are to be added to the analysis and we also have the ACF module to read ACF fields:
    https://rankmath.com/kb/titles-and-meta/#posts-custom-fields

    However, for any other custom implementation, you’ll need to include them with the help of our Content Analysis API: https://rankmath.com/kb/content-analysis-api/

    Moreover, these tests are just guidelines, and one does not need to follow them religiously. If you feel any of them don’t apply to your page, please feel free to ignore them.

    Looking forward to helping you.

    Hi Reinelle,

    Thanks for linking these documents!

    Do you have a sample script that adds a custom field to the content that is analyzed by Rank Math?

    Hello,

    Usually, the ACF plugin is the fastest way to implement a custom field on your content so our plugin can read it.

    Once you have established that, you would need to include the field name in the post settings in the Titles & Meta settings of Rank Math.

    Hope that helps and please do not hesitate to let us know if you need my assistance with anything else.

    Hello,

    Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.

    If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.

    Thank you.

Viewing 5 replies - 1 through 5 (of 5 total)

The ticket ‘Include post content in shortcodes in Rank Math analysis’ is closed to new replies.