Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter dimal

    (@dimalifragis)

    Hello again,

    Can i use this snippet i found here?

    add_filter( 'the_seo_framework_query_supports_seo', function( $supported ) {
    
    	$tsf = the_seo_framework();
    
    	// This TSF method also works in the admin area, and prevents ID collision with terms.
    	if ( $tsf->is_singular() ) {
    
    		// Define your excluded page IDs here.
    		$excluded_ids = [ 42, 9001 ];
    
    		// This TSF method supports page-as-archive pages, like blog and shop pages.
    		if ( in_array( $tsf->get_the_real_ID(), $excluded_ids, true ) ) {
    			$supported = false;
    		}
    	}
    
    	return $supported;
    } );

    Thanks

    • This reply was modified 4 years, 2 months ago by dimal.
    Plugin Author Sybre Waaijer

    (@cybr)

    Hello!

    Yes, that filter still works in TSF v4.1.1 ??

    It requires a bit of fiddling with the $excluded_ids, where you must enter the IDs of the EME pages in the array.

    Thread Starter dimal

    (@dimalifragis)

    Indeed it works. Great.

    Many thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Events Made Easy’ is closed to new replies.