Hi
I used to use this code for my previous content warning plugin:
/**
* Maybe Show Dialog
* @param bool $bool Default true
* @param WP_Post $post_ob A WP_Post object
* @return bool True to show the dialog, false to hide it.
*/
function maybe_show_dialog( $bool = true, $post_ob = null ) {
if ( is_user_logged_in() ) {
return false;
}
return $bool;
}
add_filter( 'cwv3_should_gate', 'maybe_show_dialog', 10, 2 );
Maybe we can change something with this and make it work for surbma too?
Or
If you give me the javascript codeblock of your surbma yesno plugin then I may be able to use my s2member hiding codes for it?
I saw some codeblocks in your surbma yes/no plugin file. But Im not sure which is the proper dialog code.