Skip to main content

Home/ Wordpress/ Group items tagged exclusion

Rss Feed Group items tagged

Luciano Ferrer

PHP Code To Exclude a Category From a WordPress Page - 1 views

  •  
    "function exclude_category($query) { if ( $query->is_home() ) { $query->set('cat', '-xx'); } return $query; } add_filter('pre_get_posts', 'exclude_category');"
1 - 1 of 1
Showing 20 items per page