Continue reading Premium 1.1.2

Premium 1.1.2

Difficulties getting started… Earlier versions of Relevanssi Premium miss some database fields in the database declaration, causing trouble. This version will fix the problems. Nasty little bug, and fixing it wasn’t simple – the dbDelta function WordPress uses to fix tables is very cool when it works, but a pain to debug. Download the new…

Read more Premium 1.1.2 0 Comment on Premium 1.1.2
Continue reading Premium 1.1

Premium 1.1

The first version of Relevanssi Premium is out now. For certain reasons it’s already version 1.1. Here’s what the changelog says about this version: Multisite WordPress support. See Multisite searches in Knowledge Base for instructions on how to search multiple blogs. Improved the fallback to fuzzy search if no hits……instructions to add a category dropdown to search form weren’t quite correct. They are now. It’s now possible to assign weights for post types. User profiles can be indexed and searched (see User profile search in Knowledge Base). Some of these (fuzzy search fallback, AND search, the stopword fix, WPML…

Read more Premium 1.1 0 Comment on Premium 1.1
Continue reading Multisite searches

Multisite searches

…other hand, you can adjust the settings for each blog. Enabling the multisite search There are several ways to enable multisite searching. If you want all searches to be multisite searches, you can enable multisite searching from the Relevanssi searching settings. If you want only some searches to be multisite…searches, you need to adjust search forms to include a specific parameter that will enable the multisite searching. See “Changes to the search form” below. Changes to search results templates The search results templates require some changes, otherwise, the permalinks will be wrong. Inside the while (have_posts()) loop, add as……to what multisite searching can do. There’s limited access to search parameters. You can use post_type, operator, meta_query, include_attachments and orderby. Taxonomy terms from subsites can cause problems. Searching for taxonomy terms in taxonomies that exist in the current site works: for example searching for categories from different sites works,…

Read more Multisite searches 144 Comments on Multisite searches
Continue reading Category title in the search results page

Category title in the search results page

If you’re using category restriction dropdown on your search form, here’s a bit of code that you can add to your search results template to show how many hits were found and what the category is. If no category was selected, this’ll just show how many hits were found. <?php……the category is. If no category was selected, this’ll just show how many hits were found. <?php $cat = get_cat_name( $wp_query->query_vars[‘cat’] ); $s = $wp_query->query_vars[‘s’]; echo $wp_query->found_posts . ” results found with ‘ $s'”; if ( ! empty( $cat ) ) { echo ” in the ‘$cat’ category“; } ?>…

Read more Category title in the search results page 1 Comment on Category title in the search results page
Continue reading Filter search results by date

Filter search results by date

You can specify date limits on searches with by_date search parameter. Here’s a link you can add to your search results page to offer your visitor the ability to restrict the search results to last day: <?php echo ‘<p><a href=”‘ . get_bloginfo(‘url’) . ‘?s=’ . get_search_query() . ‘&by_date=1d”>results from the…

Read more Filter search results by date 11 Comments on Filter search results by date