Skip to content

Instantly share code, notes, and snippets.

@jester1979
Last active August 31, 2017 08:48
Show Gist options
  • Save jester1979/21ae7dcb1a179897af5aa65c0571a3c2 to your computer and use it in GitHub Desktop.
Save jester1979/21ae7dcb1a179897af5aa65c0571a3c2 to your computer and use it in GitHub Desktop.
Filter the content
add_filter( 'the_content', 'cv_the_content_filter' );
function cv_the_content_filter( $content ) {
$can_user_watch_videos = cv_can_user_watch_videos();
if ( $can_user_watch_videos !== true ) {
$content = $can_user_watch_videos;
}
return $content;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment