I’ve messed up the admin search functionality. Help!
You can check if is_admin or not in the first line of the function add_filter(‘posts_where’, ‘advanced_search_query’ ); function advanced_search_query( $where ) { if(is_admin()){ return $where; } if( is_search() ) { global $wpdb; $query = get_search_query(); $query = like_escape( $query ); // include postmeta in search $where .=” OR {$wpdb->posts}.ID IN (SELECT {$wpdb->postmeta}.post_id FROM {$wpdb->posts}, {$wpdb->postmeta} … Read more