Currently the search engine included in WordPress is very limited as to what types or categories of data it can locate and how a blog user can employ the system to locate them (search mode). For example, you cannot search blog posts with a simple strategy such as "find A string in category C". You can't perform a search such as "search all categories, but not category B". It also doesn't support advanced boolean search query formats (grouping, OR, NOT, AND).
For these reasons, the WordPress search system needs an overhaul and enhancement. Members of a blog need to be able to find what they need quickly and efficiently. The search capabilities of WordPress should allow for a greater flexibility and power in search configuration and strategy so that blog users retrieve optimal relevant search results.
My proposal is to create a basis for a new search engine to replace the simple input box search currently employed. The new plugin to power the backend search would support advanced search capabilities such as boolean search, multiple content searches (posts, tags, pages, authors and any available metadata) and flags (finding posts with A string in category C).
The main feature/power of the plugin will lie in its extensibility: The plugin I propose will include the ability to drop in extension plugins (which is essentially introducing a new file in the search plugin's own plugin folder) to extend the search system. This feature will allow a user to select the search software to power the backend. This ability to customize search resources will provide a blog owner with the ability to manipulate the blog's search capability and power.
Default search components
My proposal would include several different default search components:
- a MySQL/Database plugin as the default database plugin. The new MySQL searching will offer improvements over the current search system, including multiple content searching and some flag search options.
- A Sphinx plugin that requires minimal configuration. The Sphinx searching will include multiple content type searches, flags, and advanced search types such as extended and boolean.
- A Google search module which uses Google as a backend for searching. I feel that some people would prefer to hand their searching tasks over to Google; this plugin module also allows for advanced searching capabilities as well. This module will also demonstrate that WordPress search capabilities can be supplied by third party services and APIs.
If none of these three types of default search engine enhancements are adequate for a user's needs, then a new plugin can be created by following the developer documentation to be supplied with the project, and then dropping the new plugin into the search folder.
Once a search plugin is uploaded, the user can manage it from the admin control panel; the control panel will include an enable/disable option to select which search engine to employ as well as the ability to configure any settings that might be associated with the search plugin.
In addition to the search functionality described above, the search enhancement will provide three ways to search:
- A live search mode using AJAX to search quickly on the current page using the new search syntax.
- An "advanced search" page (depending on which search plugin is selected) which provides all the available search options such as search by category, posts by a certain author, etc.