Need a unique gift idea?
A Pastebin account makes a great Christmas gift
SHARE
TWEET

Untitled

a guest Oct 12th, 2018 52 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
 
  1. <?php
  2.  
  3. function excludecategory($query) {
  4.     if(is_feed()) {
  5.         $query->set('cat','-1'); // カテゴリーIDの前に-をつける
  6.         return $query;
  7.     }
  8. }
  9.  
  10. add_filter('pre_get_posts', 'excludecategory');
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top