=== Super Speedy Search === Contributors: dhilditch Donate link: https://www.wpintense.com/ Tags: speed, performance Requires at least: 4.7 Tested up to: 5.8.2 Stable tag: 3.23 Requires PHP: 7.0 License: GPLv2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html Instant as-you-type search using native WordPress tech. == Description == Instant as-you-type search using native WordPress tech. == Frequently Asked Questions == = Is this PHP 8 compatible? = Yes, and it's MySQL 8 and MariaDB compatible too. == Changelog == = 3.23 (22nd October 2022) = * Added extra check to SQL Build to remove empty queries and avoid DB errors for those cases = 3.22 (21st October 2022) = * Fixed Smart variation search in Ajax search - if your search matches a product variation, this will now be shown in ajax just like in full search results = 3.21 (19th October 2022) = * Implemented Smart variation search + rollup - two new defines.php options - if the search matches more than 1 item in the parent product, you will see the parent, otherwise you'll see the variation - this means if a user searches 'white dresses' they'll see an archive full of white items - SSS_SEARCH_VARIATIONS - defaults to true - whether to search variations as well as parent products for woocommerce searches - SSS_ROLLUP_VARIATIONS - defaults to true - whether to group search matches to the parent (true) or show individual variations (false) * Added new Misspellings & Synonyms taxonomy - a new tag-like meta-box now appears on all post types where you can enter misspellings and/or synonyms for the item * Fixed build job so that it creates the unique wp_options(option_name) index if it doesn't exist and then correctly UPSERTS the DB version number. This fixes the issue with DB version staying 0 for new users. * Added new pre_sss_meta_keys for massive websites - add a filter on this to return an array of meta_keys to show on the META KEYS tab and we will not scan wp_postmeta * Fixed product counting bug for variations when a filter was applied. SQL was joining to children twice which meant that it was behaving as if the filter was not applied. = 3.20 (17th October 2022) = * Hardened pre_get_posts check since some themes incorrectly report is_search as true when there is no search string = 3.19 BETA (10th October 2022) = * Altered JS back to use old way of Ajax until upgrade is complete so i can merge this code to core = 3.18 BETA (10th October 2022) = * Improved weights to match mismatched titles far better - e.g. search padre hats against a product called padres hat will match better now * Added new wp-config define option define('SSS_ONLY_SEARCH_TITLE', false); - set this to true in wp-config.php if you want to force everything to only search the title. Should RARELY be used since it ruins searches based on plurals, e.g. Black Hat product, in the Hats category, with this enabled search for black hats will fail, only black hat would work. = 3.17 BETA (10th October 2022) = * Added new ajax handler with two paths for nginx/apache = 3.16 (4th October 2022) = * HotFix for searches with beta show single variations feature when using product_hidden flag = 3.15 (4th October 2022) = * Fix for SKU search against child variations, now works correctly with both new SSF beta 'show single variations' and without that option enabled. Fix requires update for SSF too. = 3.14 (23rd September 2022) * Added fix for orphaned term data left over by deactivated WPML. This fixes taxonomy search in ajax and full page results on those sites. * Added priority fix for SEARCH RELEVANCY so that it overrides Scalability Pro = 3.13 (6th September 2022) * Added new SSS_FORCE_OPTIMIZE_IN_BUILD command for fixing broken builds - removing OPTIMIZE speeds up the initial SSS build massively * Fixed bug that was causing ORDER BY searches to break if WooCommerce was not installed. = 3.12 (6th September 2022) * Moved 3 of the defines.php variables into the settings page now that they are ready - back-end search speed boost, link builder filename search removal, link builder tag search removal * Added far more speed for the link builder search * Added far more speed for edit.php search - this is where you filter most of your post types (e.g. pages and posts and most custom post types) * Fixed a bug with edit.php where ordering by date was breaking * Fixed bug with DB error if you added postmeta items to be searched and then removed them = 3.11 (5th September 2022) * Version bump = 3.10 (5th September 2022) * Added new option to prevent slow post.php link builder tag search - set SSS_REMOVE_SLOW_LINK_TAG_SEARCH true in wp-config * Added new option to prevent slow post.php link builder media filename search - set SSS_REMOVE_SLOW_LINK_FILENAME_SEARCH true in wp-config = 3.09 (30th August 2022) * Added fix for table build for users with PerconaDB to avoid using the OPTIMIZE TABLE command since it does not work efficiently on InnoDB Percona = 3.08 (19th August 2022) * Fixed order item name search so that it will continue to use open-ended wildcard search - this table is always far smaller than wp_postmeta, but in future I should add a full text index to wp_woocommerce_order_items = 3.07 (18th August 2022) * Fixed stupid little bug where order search override only enabled if you also enabled woo admin product search override = 3.06 (18th August 2022) * Added new option to upgrade the wp-admin > WooCommerce > Order search and make it far faster * Fixed a couple of warnings that appear in debug.log on first install, prior to tables being built = 3.05 (9th August 2022) * Added supress_filters => false override when SSS is kicking in - this fixes an issue with the CLASSIC link builder speed which was suppressing our overrides = 3.04 (6th July 2022) * Added new defines option: SSS_OVERRIDE_ADMIN_SEARCHES - if you define this as true in wp-config, SSS will take control of media searches and other admin searches = 3.03 Beta (9th June 2022) * Fixed DB version issue for new installs where it was trying to upgrade the tables when they didn't exist yet = 3.02 Beta (1st June 2022) * Fixed warning issue for undefined variable sss_posts_search = 3.01 Beta (23rd May 2022) * Altered query filtering priorities to be compatible with latest Super Speedy Filters and updated Scalability Pro config = 3.00 Beta (12th May 2022) * Added term update/delete hooks to maintain superspeedysearch table if users edit term descriptions or term names * Added sss_rebuild_terms function to hooks = 2.99 Beta (12th May 2022) * Added new green light system for Super Speedy Search Readiness - will help new users check if everything is ready before enabling search * Added option to enable/disable suggestions on Ajax panel * Added option to enable/disable WooCommerce wp-admin > Products search for administrators = 2.98 Beta (10th May 2022) * Added missing content weight - to config, to actual query, to weight output for admins * Added missing taxonomy description - if you store author names in the taxonomy description, they are now searchable * Added DB Upgrade code - from anything prior to 2.98, a new index will be created on wp_superspeedysearch if the table exists = 2.97 Beta (10th May 2022) * Added ?showweights URL parameter - set this to 1 on the URL to view the weights on a search results page (only visible for administrators) * Fixed bug in title weights and other text-match weights - was doing BOOLEAN match which doesn't give score = 2.96 Beta (9th May 2022) * Fixed bug in sss_update_posts hooked onto wp_insert_post to properly update superspeedysearch if woocommerce not present! * Removed a couple of warnings that were firing when saving settings without any custom suggestions added = 2.95 Beta (5th May 2022) * Removed JS console logging (was logging keypresses, ajax calls etc for debug) = 2.94 Beta (5th May 2022) * Fixed background scheduling = 2.93 Beta (5th May 2022) * Hotfix for autosuggest = 2.92 Beta (4th May 2022) * JavaScript fix for 2.91 update to use standard ajax for post-types if override definition not entered = 2.91 Beta (4th May 2022) * Removed verbose logging to debug.log * Added new definition SSS_USE_FAST_SUGGESTIONS_AJAX - SSS will now default to using normal admin-ajax.php but if your server supports it, you can add this definition to wp-config.php for faster suggestions (set it true). Add define( 'SSS_USE_FAST_SUGGESTIONS_AJAX', true ); to wp-config.php if you can allow access to plugins/super-speedy-search/sss-fast-suggestion-ajax.php * Removed cancel build button after build successfully cancelled * Fixed bug in table build causing build to fail if WooCommerce not installed * Added new toggle option to settings to enable/disable overriding search results so users can compare speeds with and without super speedy search easily * Fixed minor CSS issue with search form container * Added new fast_ajax param that gets passed to all ajax calls, even the traditionally slow ajax calls - to take advantage of this, users need to alter wp-config.php and add the following code: if (isset($_REQUEST['fastajax']) && $_REQUEST['fastajax'] == 'true') { define('WP_USE_THEMES', false); } * Improved default weights for new users = 2.90 Beta (29th April 2022) * Reduced size of batch key for temp tables to avoid exceeding 64-character limit if users have larger table prefix = 2.89 Beta (28th April 2022) * Fixed removal of start building suggestions - if you manually start the build, only the cancel button will appear on admin pages = 2.88 Beta (27th April 2022) * Removed 'Start building suggestions' button after user clicks it to avoid people clicking multiple times = 2.87 Beta (20th April 2022) * Fixed error in admin ordering of ajax post types - wasn't displaying the relevant labels for each post type in the admin area = 2.86 Beta (20th April 2022) * Fixed broken weights after refactoring from 2.83 = 2.85 Beta (20th April 2022) * Added cancel button to suggestions build - useful if build was stalled from hosts cancelling long-running queries and admin/user is running initial SQL manually = 2.84 Beta (18th April 2022) * Added sss_rebuild_terms function to rebuild wp_superspeedysearch_terms when terms are altered - fixes taxonomy search = 2.83 Beta (18th April 2022) * Added @twardys updated SALES flash styling - looks great! * Remove some of @marins css customisations as they were site-specific * Fixed initial load of first settings tab to hide the weights * Added new option for 'strict search' - reintroduces the +search +word modifier which forces the query to require all words - faster and more accurate results * Added default numitems of 5 for new users for ajax search result count * Added new function for admins doing imports which bypass do_action calls - if do_action bypassed, users need to call sss_update_posts($post_id) with a post_id or an array of post_ids = 2.82 Beta (18th April 2022) * Refactored sss.php to have better interoperability with super speedy filters * Removed unused files * Fixed meta fulltext search to only search relevant meta_keys * Removed some PHP warnings * Added static boost for matching meta values * Added taxonomy descriptions to ajax output = 2.81 Beta (3rd April 2022) * Added $post->ID to get_permalink call = 2.80 Beta (31st March 2022) = * Added code to handle container polyfill * Then removed it because it's sluggish * We have 1 column, it can be overridden with very easy CSS = 2.79 Beta (30th March 2022) = * Merged @Marins CSS edits to make results panel two columns * Fixed date weights from postmeta - if used, they were breaking relevance and things were in any order * Altered default weights to be more sensible to help @Daniel = 2.78 Beta (21st March 2022) = * Fixed bug in widget panel toggle = 2.77 Beta (21st March 2022) = * Removed + from fulltext searches which adds extra weaker results to pages which otherwise have no results * Altered JS code to run post-type searches after suggestions success rather than complete since we sometimes abort these - they weren't being aborted properly - reduces overall connections required * Added option to disable Ajax panel which reduces DB connections required * Altered JS to check if taxonomy query needs to run (if none selected, it does not need server call) * Added $wpdb->close() to fast-suggestion-ajax.php to ensure connections closed as early as possible rather than wait for regular garbage collection * Updated suggestions builder to improve contractions and keep tokens separated when they should be = 2.76 Beta (15th March 2022) = * Updated wp_insert hook to also update 'pending' posts * Updated table build to properly use utf8mb4 AND avoid the MySQL bug related to fulltext indexes and virtual columns from here: https://bugs.mysql.com/bug.php?id=102833 * Added new age-hours weight for admins who store dates in postmeta - users can reduce the score for older items = 2.75 Beta (9th March 2022) = * Updated plugin updater to update directly from bitbucket, not from wpintense = 2.74 Beta (3rd March 2022) = * Added review star ratings stylings for products in ajax panel (thanks to @twardy again!) = 2.73 Beta (25th February 2022) = * Removed collation definitions from tables - will inherit the defaults - still to triple check if this is ok for Greek and other extended character set languages * Added Suggestions tab to settings page * Added option to configure minimum occurrences of a phrase in your documents before it will be considered as a search suggestion (default 2) * Added panel to add custom suggestions * Added panel to remove suggestions = 2.72 Beta (23rd February 2022) = * Added new styling from @twardy - includes product prices, product categories(meta) and some other improvements = 2.71 Beta (22nd February 2022) = * Fixed bug in table generation for per-post-type weights = 2.70 Beta (17th February 2022) = * Altered weights to be per-post-type - allows different weights to be configured per post type = 2.69 Beta (16th February 2022) = * Improved admin CSS for settings pages * Fixed Ajax Num Items config - it was stuck on 5 in front end * Fixed Button Position config so See All button in ajax panel can be placed top, bottom, or hidden * Re-added the missing search icon prefix to the See All button * Added extra JS to wipe the ajax panel contents when a user starts typing something new * Added an event handler to paste in case users right-click paste instead of keyboard shortcuts * Fixed weird bug where if you CUT what was in the searchbox and re-pasted it, nothing would happen. It now correctly produces the search results again. * Updated the z-index of the search form to 999 instead of 50000 so it goes BEHIND menus instead of staying on top! = 2.68 Beta (15th February 2022) = * Made Ajax Post Types movable so users can choose order of post types in the ajax panel * Added missing index to table rebuild for admin product search * Added table maintenance of superspeedysearch table - no need for rebuild now * Increased min-height of super speedy search text box - recent CSS made it possible for this to look quite skinny and weird * Added SSS_REPLACE_HYPHENS define, default to true, makes SSS replace hyphens with spaces when searching * Added SSS_REMOVE_PLUSES define, default to true, makes SSS remove + symbol in search string. Fixes phone number searches. = 2.67 Beta (11th February 2022) = * Fixed bug with merge which meant new panel div was not output * Minor update for rating and ON SALE flash in ajax panel = 2.66 Beta (11th February 2022) = * Added @twardys new improved visuals for the ajax panel = 2.65 Beta (11th February 2022) = * Fixed query error for search results with filters * Added ajax panel to Appearance > Widgets - it will run against the search string entered + the default post type chosen in the settings page = 2.64 Beta (10th February 2022) = * Added config per post type for the Ajax search results panel = 2.63 Beta (9th February 2022) = * Fixed bug with alpha table build - columns were in wrong order for insert! * Table build has not failed on any demo/dev sites now, looks stable * Fixed bug with Custom Meta Value weights not being used correctly = 2.62 ALPHA (9th February 2022) = * Fixed CSS to make search box appear underneath Query Monitor admin interface = 2.61 ALPHA (8th February 2022) = * Made all weights optional * Denormalised meta_value checks for weights into superspeedysearch table for improved performance * Added experimental option for a faster way to check product visibility - requires define( 'SSS_FAST_VISIBILITY_CHECK', true ); be added to wp-config.php = 2.60 BETA (2nd February 2022) = * Added weights to options page and to results relevancy - many types of weights + custom weights = 2.59 BETA (1st February 2022) = * Added tabs to settings page = 2.58 BETA (28st January 2022) = * Improved rebuild jobs further - made them work on multisite! * Added DEFINE option to hide the ajax panel when the window scrolls: Add define( 'SSS_HIDE_AJAX_ON_SCROLL', true ); to wp-config.php if you want to test this * Fixed detection of fulltext index for main queries - in some cases LIKE operator was still being used! = 2.57 BETA (21st January 2022) = * Added language file so users can use Loco Translate to alter pieces of text * Fixed keyboard control so users can go between suggestions and products and posts with up and down arrows = 2.56 BETA (20th January 2022) = * Added term counts and a check to not suggest empty terms * Removed overlay * Added specific filter for porto * Grouped taxonomy suggestions and ordered by size * Fixed reset button to actually clear the box and hide the suggestions = 2.55 BETA (20th January 2022) = * Added new table to handle fulltext search for wp_terms, wp_term_taxonomy and wp_termmeta - this improves taxonomy searches so that they are faster AND improved - e.g. searching for Author name Iain Banks will work the same as if you search Banks Iain * Added fulltext search for taxonomies to both ajax output and to full search results * Fixed ajax tax search so it actually takes into account the config of which taxonomies to search * Improved styling of taxonomy matches on full page search results * Removed limit on how many taxonomies to match in ajax panel = 2.54 ALPHA (19th January 2022) = * Fixed bug with suggestions table build on non-wp_ prefixes including fixing suggestions on multisite * Added Super Speedy Search logo to bottom of ajax panel = 2.53 ALPHA (18th January 2022) = * Further improvements to ajax panel styling = 2.52 ALPHA (14th January 2022) = * Improved ajax panel styling * Added 2 columns by default to the search and tax suggestions * Added 4 columns by default to the post types search results = 2.51 ALPHA (13th January 2022) = * Fixed priority ordering of Super Speedy Search CSS so that Customiser can override the styles = 2.50 BETA (6th January 2022) = * Added override search form and override product search form options to help with theme integration * Added ajax item display template option - grid or list, default grid * Re-arranged settings page to keep items together better = 2.49-3 ALPHA (5th January 2022) = * Overhauled the batch process system to be ultra reliant * Added localisation for 'Search Suggestions' text = 2.49-2 ALPHA (4th January 2022) = * Fixed warning about searchorder index being missing * Made batch process more resilient = 2.49-1 ALPHA (4th January 2022) = * Fixed detection of fulltext indexes to check properly against superspeedysearch table * Fixed bug in generating tables with certain GROUPBY configs of mysql * Fixed bug in generating tables with no taxonomies selected = 2.48 BETA (29th December 2021) = * Switched to using named columns for suggestions table build - found customer who had extra columns defined on their wp_posts table which was breaking my suggestions build = 2.47 BETA (17th December 2021) = * Hardened plugin update checker so it doesn't crash if WPI not available = 2.46 BETA (15th December 2021) = * Fixed CSS for search form to have light border = 2.45 BETA (15th December 2021) = * Added additional default search form override so this works by default out the box for most themes = 2.44 BETA (15th November 2021) = * Fixed SSS_WP_Background_Process class (third party library) to be object cache compatible - it runs smoothly now with object cache on * Added taxonomy search suggestions to ajax * Added SSS_STOP_WORDS define - users can define this to overrule the stop words by adding define('SSS_STOP_WORDS', 'space separated stop words'); to wp-config.php - this will move out of define in future into admin panel = 2.43 BETA (10th November 2021) = * Made SSS_WP_Background_Process unique name since it's slightly modified to work better with object caches = 2.42 BETA (10th November 2021) = * Table build improved to have better defaults - users can click the button immediately to get search suggestions built and super speedy search working * Still some admin issues in this: Maintenance of suggestions and main table not happening, progress bar never disappears, progress bar affects styling of wp-admin = 2.41 BETA (8th November 2021) = * Added suggestions - includes a big table build which currently works only when the object cache is switched off - I've still to fix this third party library so it works properly with the object cache (they mix reading options data through functions and directly from tables) * This release is a BIG one - the table build takes about an hour on foundthru, but it results in instant as-you-type search suggestions = 2.40 BETA (3rd September 2021) = * Added new wp_superspeedysearch table - this copies posts + space-separated values from wp_terms.name and wp_term_taxonomy.description - this allows fulltext searches like 'dior dress' where both 'dior' and 'dress' are in the wp_terms.name column = 2.39 BETA (3rd September 2021) = * Altered taxonomy search to search tax description and tax meta too. Note: Not yet optimised! There's not often a lot of data in wp_termmeta, but if you do this might not be fast yet. = 2.38 BETA (3rd September 2021) = * Refactored post_status code = 2.37 BETA (3rd September 2021) = * Changed used of strlen(token) < 3 to mb_strlen(token) < 3 - fixes issue with searching in WPML for items with 2 character search strings * Improved ESC handler to close results, added extra code to close popped out search form on porto * Added extra posts_per_page setting to allow users to configure full search results count as well as how many posts per ajax grouping to fetch = 2.36 BETA (1st September 2021) = * Fixed WPML compatibility - this includes a bug that was causing products to return in the ajax results posts section. All fixed now. * Search accuracy improved and results more relevant * Removed some debug messages = 2.35 BETA (31st August 2021) = * Fixed search button text in widget and shortcode - if you set searchbutton text, the button will have that text, if you leave the text empty it will use our search icon * Added override for Order search to change it from LIKE '%searchstring%' to LIKE 'searchstring%' which allows full use of the index from scalability pro = 2.34 BETA (30th August 2021) = * Fixed sorting by date override * Improved relevancy significantly so searched titles are at the top (needs a new index to be created) * Fixed bug causing items with stop words in their title being excluded from the results * Fixed bug causing private items to be hidden from All search in wp-admin = 2.33 BETA (20th August 2021) = * Added get_search_form override for Woodmart search replacement (and other themes) * Added FontAwesome font-face for search icon, loaded locally with webfont = 2.32 BETA (19th August 2021) = * Fixed warning for missing setting for taxonomy deepsearch on fresh installations * Added better output info for failure to create fulltext indexes = 2.31 BETA (5th August 2021) = * Removed rewriting of page title when typing - no one liked it = 2.30 BETA (30th July 2021) = * Removed warnings from widget * Removed excess logging = 2.29 BETA (27th July 2021) = * Added translation for search button title * Fixed the orderby clause so we only override for RELEVANCE if no other orderby is specified = 2.28 BETA (27th July 2021) = * Added code to avoid overruling the orderby and order settings if $_GET['orderby'] is set - check with Marin if this fixes things in his theme = 2.27 BETA (27th July 2021) = * Added CSS for font-awesome icons and to fix square images * Altered code to try and grab the shop_catalog thumbnail for the items rather than the fullsize images, falls back to thumbnail - includes a placeholder image now too (easily alterable using CSS) * Improved CSS for the ajax results to be more visually appealing = 2.26 BETA (26th July 2021) = * Removed old excess JS that was causing JS error on woo archive pages = 2.25 BETA (22nd July 2021) = * Added _e around customizable $searchplaceholder - for those using multiple languages * Added See All link into post type headers in Ajax search results * Improved search results URL to only include the post_type and not the additional ajax_post_types parameters * Added default post type option to settings which controls which template is used and what to search when user hits ENTER or taps the search icon * Improved visual results of taxonomy searches displayed above WooCommerce products (for now, taxonomy searches appear in Ajax panel and WooCommerce products but search continues to work across all post types) = 2.24 BETA (16th July 2021) = * Fixed bug introduced in 2.23 which had fixed search RESULTS but broke AJAX inline results when multiple post types selected = 2.23 BETA (16th July 2021) = * Fixed post_type in search form to include post_type[] since it is an array - fixes search result pages for multiple post types, so all post types are searched = 2.22 BETA (16th July 2021) = * Fixed shortcode so that it respects the post_types you pass - this allows you to overrule the global post_types settings for each search widget you create * Added per-post type sections to ajax search results - so you'll see 'posts' then 'products' then whatever other post types you chose in your shortcode (or global setting if you dont set a post type in the shortcode) * Added minimum 3 character limit for ajax search to save server resources * Fixed out of stock so both ajax and full results properly respect whatever you have configured in WooCommerce * Added extra section to per-post type sections for just top level categories without search parameter applied - this is for the tax name search * Added Ajax results per post type option to allow control of num results per post type in the ajax panel * Added option to remove Ajax excerpt so users don't need to edit template files for this alteration = 2.21 BETA (6th July 2021) = * Fixed CSS issue with ajax response headers = 2.20 BETA (6th July 2021) = * Fixed ajax search results to honour the taxonomy settings - will search each taxonomy for matching items and show the link to a search within that taxonomy * Removed the need for translations in the Ajax search results * Changed taxonomies to labels, and moved the search string into the taxonomy header in ajax search results = 2.19 BETA (6th July 2021) = * Refactored search to be completely compatible with WPML and Polylang, no longer reconstructing the query and it's still lightning fast * Re-Added date search and posts per page * Removed author search options as it was really 'user' search - may reintroduce later in a different way - perhaps in search results template listing matching author links to view all their articles * Removed order by option - it orders by relevance only - the others are not fast enough yet to have the WPI brand on them * Improved relevance sorting = 2.18 BETA (2nd July 2021) = * Added term_relationships join for WPML and Polylang when they're present = 2.17 BETA (2nd July 2021) = * Added additional porto-theme-specific code to handle sticky headers, search pop out etc * Changed GO to search icon from font-awesome * Improved styling of ajax results panel in various ways * Added input focus handler to show results panel when input box is refocused so users see their previous search * Changed top category matches (showing counts of all items in that cat) to display as labels - makes the search panel a little more interesting at the bottom * Fixed container to use 100% of width to work inside whatever panel developers add the widget/shortcode to = 2.16 BETA (1st July 2021) = * Added ajax dropdown onto the SHORTCODE ONLY at this point - the widget currently still updates the WooCommerce archive if there is one * Added template system for ajax dropdown results * Added full functionality for this, but no options to configure it yet - options are all hardcoded - dropdown contains image, title, categories, excerpt and if it's a product it also contains the flash (on sale, featured), rating and price * Added second list in ajax dropdown containing matching taxonomies and the counts of items matched - clicking this takes you to, for example, /dogs/?s=dog+bed = 2.15 BETA (9th June 2021) = * Improved searches containing word separators like ./+-\ * Fixed searches with double quotes " = 2.14 BETA (9th June 2021) = * Changed top 100 to top 1000 * Hardened search with LIKE operator against the reduced result set - particularly important for words containing periods like 2.5" or 3.5" etc * Hard coded in WORD DISTANCE booster to the score - if words are close together (closer than 5) then that row gets a score boost * Hard coded in TITLE LENGTH reduction to the score - this makes pages with smaller title lengths more relevant because otherwise the relevancy score prefers titles that mention words more than once - e.g. HDD CASE, Takes any HDD Drive - HDD mentioned twice so gets higher score normally than 2.5" HDD * Hard coded in IN STOCK score booster - obviously only relevant to products, but will not break other non-product searches with other post types = 2.13 BETA (24th May 2021) = * Perf update - wrap union in ()s and select top 100 from each pre-union = 2.12 BETA (28th April 2021) = * Refactored how this works, made it simpler to maintain * Rewrote how postmeta queries work - they've been altered to use a UNION instead of a LEFT JOIN. FAR faster now. * Updated functions to make integration with FWW far faster * NOTE: This Beta version includes missing functionality - taxonomy searches will do nothing and it will only ever order by relevance, not by date. - i altered the query using alter_query filter - would be better to alter the query using the SEARCH filter and perform an IN statement to restrict the posts = 2.11 (6th April 2021) = * Added a filter for wp-admin woo product search to use fulltext indexes, if they are created = 2.10 (6th April 2021) = * Improved speed of meta search queries * Improved relevance of all queries - best results at the top * Added special case for "phrase-matching" when hyphens exist in the token * Fixed bug in non-fulltext meta search - it now respects CONTAINS, STARTSWITH or ENDSWITH depending on what you set in the settings page = 2.09 (22nd October 2020) = * Fixed bug with non-full text search which was causing searches to only search LIKE 'xxx%' rather than LIKE '%xxx%' = 2.08 (30th September 2020) = * Added new WPI Settings page where users can enter their license key to enable plugin updates = 2.07 (2nd September 2020) = * Removed superfluous plugin links on wp-admin -> plugins page * Altered wp_postmeta SQL to use nested IN rather than WHERE EXISTS - this improved speed AND fixed the related bug with FWW = 2.06 (15th July 2020) = * Fixed bug in multisite detection so that fulltext search will work properly in networked sites * Fixed issue with shortcode when restricting results to specific taxonomies, this was causing WP_Query to add AND (0 = 1) = 2.05 (24th June 2020) = * Added tax and taxslugs parameters to superspeedysearch shortcode - if you use [superspeedysearch tax="product_cat" taxslugs="dogs"] then this search box will restrict the searches to the product category dogs only = 2.04 (23rd June 2020) = * Re-added ajax capability to widget (ajax still only works for WooCommerce archives) * Removed unused fields from widget * Fixed broken 'spinner' when ajax searching * Fixed post_type URL parameter so search result template will be picked up properly * Added wildcard searching on fulltext indexes by default - very little perf difference, so on by default as it IS expected behaviour by most people * Cleaned up JS a bit, removing unused variables and URL parameters to make search results page cleaner * Removed keyup ajax detection when enter key hit - this allows user to hit enter to actually go to fresh new page if they wish, rather than just the ajaxed page = 2.03 Beta (22nd June 2020) = * Added multisite compatibility * Added cache to settings page so 2nd+ visits on same day will be fast (it's slow to look up all the possible meta fields) = 2.02 Beta (26th May 2020) = * Fixed empty result sets when using tokens < 3 characters (will improve further to allow this to be configurable if you alter minimum token size in mysql config) = 2.01 Beta (22nd April 2020) = * Added automatic inclusion of subchildren of taxonomies. If user searches for Dresses, it will match products within Dresses->Formalwear rather than just at ->Dresses = 2.00 Beta (16th April 2020) = * Complete overhaul of settings page to allow full config over what to search * Search posts, custom posts, taxonomies, or attributes * Reduced 3 fulltext indexes to 1 to save space (user needs to click button to create the required fulltext index after config) * Improved accuracy of search by using token1+ token2+ to require both tokens but any spacing apart in the searched index * Improved speed of fulltext search - now on foundthru (800,000 products) the fulltext search takes about 100 milliseconds https://foundthru.com/?s=harry+potter&post_type=product * Search has been made fully compatible with latest beta of Faster Woo Widgets so it's easy to drill down on search results - e.g. https://foundthru.com/?s=harry+potter&post_type=product shows toys, books and games * Product counts in Faster Woo Widgets sidebar now reflect the Super Speedy Search results * Added check against in-stock products according to WooCommerce config * Added options for users to use standard LIKE operator (definitely not recommended!) = 1.27 (7th August 2019) = * Fixed activation issue causing index to not be created! = 1.26 (25th June 2019) = * Fixed warning notice when changing settings for widget in wp-admin -> Appearance = 1.25 (4th March 2019) = * Added new fulltext index to wp_postmeta - currently used in orders search * Removed meta_tag list on settings page - was too slow = 1.24 (6th October 2018) = * Hotfix to fix search adding products to empty archive page (including pagination, so scrolling and pagination will work) = 1.23 (6th October 2018) = * Improved code so it never replaces the text box in the sidebar (was happening in some themes), so now you can keep typing with ajax * Increased the time to wait for user to stop typing to 200ms to reduce load on server * Improved compatibility with auto infinite scroll * Fixed issue where ajax stopped working if a search returned 0 products and then user continued typing - now ajax works instead of page refreshing to new page * Fixed issue where products were disappearing sometimes * Fixed issue where text box was not remaining populated in the widget on page refresh * Fixed issue where if a search returned only 1 item, woocommerce was preventing it appearing in the ajax search results * Added available meta_fields to settings page as a convenience so it's easier to build your list of searchable meta data = 1.22 (24th May 2018) = * Added full wildcard option for users who need to search attributes * Re-added ajax search option (now working properly) = 1.21 (23rd January 2018) = * Fixed deactivation error that would occur if user had not created fulltext index somehow = 1.20 (17th January 2018) = * Added superspeedysearch shortcode * Added extra info to settings page to explain meta_keys (_sku most common) * Added JS to strip leading # for users using that to search SKUs = 1.19 (4th January 2018) = * Removed unused shortcode option * Removed 'search as you type' - was causing too many bugs - will re-introduce along with auto-complete - i.e. for slow typers, we'll guess what they're typing, auto-complete and auto-search. Otherwise empty results appear and the search box clears. * Altered default search to 'best relevance' (even when widget not used) * Added 2 new sorting options - sort by recent items and sort by relevance + date weight * Added settings page to allow non-widget search to be configured * Added option to disable ajax and send userst to normal search results page = 1.18 (22nd December 2017) = * Fixed bug preventing proper use of search templates when more than one post_type searched * Fixed bug when widget used on page which contained 'related products' but no actual products archive (was filling the related products instead of the archive) * Added 'relevancy' sort ordering to admin page and back end search results - now users can choose to order by a variety of relevancy scores = 1.17 (30th November 2017) = * Added JS trigger event after Super Speedy Search complete called super-speedy-search-complete - useful for other developers who implement things like lazy load in their themes so that their code can run after super speedy search has updated the page * Added search placeholder text option for customisation and internationalisation * Added search button text option too * Added option to allow searching of wp_postmeta - admin can choose meta_keys to search = 1.16 = * Improved speed when user hits ENTER (instead of waiting 450ms after keypress) * Fixed widget on non-archive pages, now search redirects to traditional search results pages