apply_filters ( 'wordads_inpost_disable', bool true )

Allow third-party tools to disable the display of in post ads.

Source file: modules/wordads/wordads.php

View in GitHub

Parameters

true

(bool) true Should the in post unit be disabled. Default to false.


Changelog

Since: Jetpack 4.5.0


Notes

You can use this filter to disable Ads appearing below the post content in specific situations. In the example below, we’ll disable all Post ads:

/**
 * Disable Ads appearing below the post content.
 */
add_filter( 'wordads_inpost_disable', '__return_true' );

Comments

  1. Manni de Man says:

    Not working, please provide exact description and implementation advise. Also please let me know why there’s a different syntax here compared to github

  2. angelonfire says:

    Thank you this worked for me after I enabled the ads on accident. Added it to my functions.php and bingo!

    • Jeremy says:

      I’m glad to hear it helped! Were you not able to deactivate the feature altogether, if you don’t want to display ads at all on your site?

      If you experienced issues when trying to deactivate the feature, you can contact us through this form and we will help you sort this out!

Have a note to contribute?

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s