Include Author profile in search results

If you have a user role called “consultant” and you do a search filtering by capability “consultant”, you wouldn’t find anything. Roles and capabilities are different things. Here is the codex reference: http://codex.wordpress.org/Roles_and_Capabilities

How do I change WP search results order?

You can use the action hook posts_orderby in your child themes functions.php: function changeSearchSort( $orderby, $query ){ global $wpdb; if(!is_admin() && is_search()) { $orderby = $wpdb->prefix.”posts.post_date ASC”; } return $orderby; } add_filter(‘posts_orderby’,’changeSearchSort’,10,2);

Replace URL with Site Title in Search Results

What you are seeing is correct. Google display in SERPs (Search Engine Results Pages) listing as follows: URL Page Title Page Description [ other attributes (potentially) ] Your top result: Tattini Boots – 1860 | Italian English Riding Boots – U.S Links to: https://www.tattiniboots.com/ …your homepage.

How to search through pdf media files?

The built in WordPress search doesn’t index PDF file contents, however Google does, there’s a good tutorial on DevPress on replacing WordPress search with Google Custom Search.

How to exclude post body from WP search

To remove elements from being searched, use the post_search filter to amend the SQL query for the search e.g. only pull in the title. function ni_search_by_title_only( $search, &$wp_query ){ global $wpdb; if ( empty( $search ) ) return $search; $q = $wp_query->query_vars; $n = ! empty( $q[‘exact’] ) ? ” : ‘%’; $search = $searchand … Read more