• christopheran

    (@christopheran)


    Hi all,

    I’m the developer of a plugin that adds a subscription service to WP sites so, for example, you can set up a paywall for specific posts/pages.

    I’m trying to figure out the best way to handle schema on paywalled pages. Google says to set “isAccessibleForFree” to “False”.

    Some seo/schema plugins add “isAccessibleForFree”:”True”? to the schema by default and don’t have an option to make that “false”, others include the option, but I’d like to set things up so that my plugin automatically adds “false” to all pages that are paywalled.

    I’m trying to brainstorm out the best way to handle this.

    I’m wondering if it would be appropriate to have a setting that publishers can select to search/replace “isAccessibleForFree”:”True” to “isAccessibleForFree”:”False” in the schema that is outputted by other plugins on all paywalled pages, if that is even possible.

    Do you have another thoughts on how that might be done?

    Chris

Viewing 2 replies - 1 through 2 (of 2 total)
  • threadi

    (@threadi)

    The best way would be for the plugins in question to provide hooks to customize these outputs. If and how they do that, you can see in their source code or ask their developers about it.

    Otherwise there would be the sledgehammer method: an output buffer that you put around the whole output and parse and adjust the source code before the output…. A rough example is described here in the 2nd answer: https://wordpress.stackexchange.com/questions/52840/filter-all-html-output

    Thread Starter christopheran

    (@christopheran)

    Thanks threadi,

    Sledgehammer method – I like that description. I’m working on a couple of things I’m checking into, but if most of the major seo plugins have hooks that I can use, I’ll go that way, just have to dig into them ??

    Chris

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Appropriate for a plugin to change the output of another plugin?’ is closed to new replies.