/ Published in: PHP

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
function SearchFilter($query) { if ($query->is_search) { $query->set('cat','0,1'); } return $query; } add_filter('pre_get_posts','SearchFilter');
Comments
