Giter Club home page Giter Club logo

algolia / algoliasearch-wordpress Goto Github PK

View Code? Open in Web Editor NEW
360.0 103.0 116.0 30.34 MB

βŒπŸ—‘πŸ™…β€β™‚οΈ Algolia Search plugin for WordPress is no longer supported. Please use our API client guide instead

Home Page: https://www.algolia.com/doc/integration/wordpress/getting-started/quick-start/

License: GNU General Public License v2.0

JavaScript 77.09% PHP 21.87% CSS 0.81% Shell 0.23%
algolia php wordpress search-engine

algoliasearch-wordpress's Introduction

Search by Algolia – Instant & Relevant results

Contributors: algolia, rayrutjes
Tags: Search, Algolia, Autocomplete, instant-search, relevant search, search highlight, faceted search, find-as-you-type search, suggest, search by category, ajax search, better search, custom search
Requires at least: 4.4
Tested up to: 5.0
Requires PHP: 5.3
Stable tag: 2.11.3
License: MIT License, GNU General Public License v2.0

Search by Algolia is the smartest way to improve search on your site. Autocomplete is included, along with full control over look, feel and relevance.

Plugin sunset

TL;DR: This plugin is no longer supported. Please use our API client guide instead https://www.algolia.com/doc/integration/wordpress/getting-started/quick-start/.

After discussing with a lot of you, we've realized that our WordPress plugin, while being easy to implement and use, did not provide the room for customization necessary to build satisfying, advanced search and discovery experiences on Wordpress websites.

That's why we have decided to double down on our new PHP API client instead. We created comprehensive documentation to guide you to index your Wordpress content, optimize your relevance, and build state-of-the art front end experiences relying on the API client.

We believe this approach is the most robust, satisfying and future-proof way to build great experiences for Wordpress websites. We will therefore stop supporting our WordPress plugin following this timeline:

  • From 02/05/19: we won't add any new feature or fix any new functional bug in our Wordpress plugin.

  • From 31/12/19: we won't provide any security fix to our Wordpress plugin

Please note that if you already have the plugin set up and are satisfied with your current integration, you can keep using the plugin forever, knowing that it won't be supported according to the timeline above. It will still work as is, in its current state, on your website.

Description

The plugin provides relevant search results in milliseconds, ensuring that your users can find your best posts at the speed of thought. It also comes with native typo-tolerance and is language-agnostic, so that every WordPress user, no matter where they are, can benefit from it.

About pricing

This plugin relies on the Algolia service which requires you to create an account here. Algolia offers its Search as a Service provider on a incremental payment program, including a free Community Plan which includes 10,000 records & 50,000 operations per month. Beyond that, plans start at $29/month.

Note that there isn’t a direct correlation between the number of posts in WordPress and the number of records in Algolia. Also note that we only offer support starting from the PRO plan. On average, you can expect to have about 10 times more records than you have posts, though this is not a golden rule and you could end up with more records.

Getting started guide

Once you have installed the plugin, you can follow the step by step guide provided here: https://community.algolia.com/wordpress/configuration.html

Relevance

Algolia enhances your search functionality with a completely customizable search experience which can be seamlessly integrated into your Wordpress theme. It lets you create a find-as-you-type experience or an auto-complete dropdown menu, which provides relevant results from the first keystroke. Our extension also automatically synchronizes data (posts, taxonomies etc.) in real-time, making sure that any updates to your site are available as soon as they are made.

Speed

Algolia returns results in under 35ms on an average – irrespective of whether you have 100s or 1000s of posts. Our state-of-the-art infrastructure and distributed search network ensures that your readers benefit from this, no matter where they are.

Accessibility

Search by Algolia gives you the ability to make all forms of data – blog posts, categories, users etc. – searchable from a single search bar. Algolia also gives you the ability to completely customize your search results based on criteria that makes sense for your business, such as popularity, date, relevance etc.

Built by developers for developers

Search by Algolia is also completely configurable and fully extensible by means of WordPress filters and hooks, letting you build a custom search experience or theme based on Algolia.

Want to see out how we did it?

Check it out here: Search by Algolia GitHub Repository

Join the Algolia community and meet thousands of search enthusiasts. We’re also always on the lookout for feedback: https://community.algolia.com/wordpress

Frequently Asked Questions

Where can I find Search by Algolia documentation and user guides?

Will Search by Algolia work with my theme?

Yes; Search by Algolia will work with any theme, but the Instant Search results page may require some styling to make it match nicely.

Where can I report bugs or contribute to the project?

Bugs can be reported either in our support forum or preferably on the Search by Algolia GitHub repository.

My issue is not listed here, what should I do?

Please check out the Frequently Asked Questions on our website which might have more information than this thread. It will also give you guidance about where to ask support if your question is not covered.

Installation

Minimum Requirements

  • PHP version 5.3 or greater (PHP 5.6 or greater is recommended)
  • MySQL version 5.0 or greater (MySQL 5.6 or greater is recommended)
  • Some payment gateways require fsockopen support (for IPN access)
  • Requires WordPress 4.4+

Visit the Search by Algolia server requirements documentation for a detailed list of server requirements.

Automatic installation

Automatic installation is the easiest option as WordPress handles the file transfers itself and you don’t need to leave your web browser. To do an automatic install of Search by Algolia, log in to your WordPress dashboard, navigate to the Plugins menu and click Add New.

In the search field type β€œAlgolia” and click Search Plugins. Once you’ve found our search plugin you can view details about it such as the point release, rating and description. Most importantly of course, you can install it by simply clicking β€œInstall Now”.

Manual installation

The manual installation method involves downloading our search plugin and uploading it to your webserver via your favourite FTP application. The WordPress codex contains instructions on how to do this here.

Updating

Automatic updates should work like a charm; as always though, ensure you backup your site just in case.

Screenshots

1. Algolia Settings.

Algolia Settings.

2. Indexing configuration.

Indexing configuration.

3. Instant-search results configuration.

Instant-search results configuration.

4. Autocomplete dropdown configuration.

Autocomplete dropdown configuration.

5. Autocomplete dropdown example.

Autocomplete dropdown example.

6. Instant-search results page example.

Instant-search results page example.

Changelog

Checkout the complete changelog here.

algoliasearch-wordpress's People

Contributors

avigoldman avatar bobylito avatar christirichards avatar claudiuceia avatar diedexx avatar fperroamiral avatar gaetanfa avatar haroenv avatar jedrzejchalubek avatar julienbourdeau avatar lukyvj avatar mamaduka avatar maxiloc avatar neilrichler avatar petenelson avatar peterdavehello avatar piersb avatar plnech avatar raae avatar rayrutjes avatar redox avatar royduin avatar shipow avatar sir-daniel avatar spone avatar tobiasvielmetter avatar vvo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

algoliasearch-wordpress's Issues

Questions

Hello--

The more i've been testing your plugin, the more I'm liking how you have set it all up. I do have a couple of questions that I'm hoping you can help me answer.

  1. First, I know that another issue was opened and subsequently closed regarding excerpts. Your response makes sense; however, I'm having a similar issue because we create custom excerpts for our articles. The critical reason for this involves short codes: for example, if we open an article with a short code (like a video), then the short code syntax is what appears in the excerpt within the search results. I know you mentioned the attributesToSnippet as an option. How would this work? Is there a way to connect that attributes function to a post's excerpt that is already saved in the database?
  2. Is there a way to add filters to the search request sent to Algolia? In our situation, we use a membership plugin to protect content based on post type and category depending on user role. The facetable section you offer is great, but there are some facets I would not want certain users to ever see. I'm currently using a pre_get_posts filter for standard WP Query to filter results. I looked inside the Query Replacer class but didn't see a hook for adding/modifying the query. Any suggestions on this?

Thank you for your plugin and your time!

Problem with Algolia Plugin

Hello
I want to use the Algolia Plugin for Wordpress. But I have been facing a problem.
After filling in the credentials, browser does not get redirected anywhere.
Also, the interface for the settings looks nothing like the one shown on the Github page(the 7 bars on top are not peresent).

Help will be appreciated
Thanks

All records have blank attributes

{
  "requests": [
    {
      "action": "updateObject",
      "body": {
        "objectID": "2",
        "title": "",
        "content": "",
        "category": [
        ],
        "author": "",
        "type": "",
        "date": "",
        "author_login": "",
        "modified": "",
        "parent": "",
        "permalink": "http://192.168.59.103/?page_id=2",
        "slug": ""
      },
      "objectID": "2"
    }
  ]
}

Error on publishing or updating blog posts and woo products

When publishing or updating a post, I get the following error. Deactivating the Algolia plugin fixes the issue. Thank you.

Notice: Undefined index: default_attribute in /www/wp-content/plugins/algoliasearch-wordpress-master/AlgoliaPluginAuto.php on line 76 Fatal error: Uncaught exception 'Exception' with message 'Unknown attribute: meta' in /www/wp-content/plugins/algoliasearch-wordpress-master/core/Registry.php:68 Stack trace: #0 /www/wp-content/plugins/algoliasearch-wordpress-master/core/Indexer.php(109): Algolia\Core\Registry->__get('meta') #1 /www/wp-content/plugins/algoliasearch-wordpress-master/AlgoliaPluginAuto.php(77): Algolia\Core\Indexer->indexTerm(Object(stdClass), 'category') #2 [internal function]: AlgoliaPluginAuto->termTaxonomyUpdated(5, 'category') #3 /www/wp-includes/plugin.php(496): call_user_func_array(Array, Array) #4 /www/wp-includes/taxonomy.php(4101): do_action('edited_term_tax...', 5, 'category') #5 /www/wp-includes/taxonomy.php(3672): _update_post_term_count(Array, Object(stdClass)) #6 /www/wp-includes/taxonomy.php(3645): wp_update_term_count_now(Array, 'category') #7 /www/wp-includes/post.php(5909): wp_update_term_count(Array, 'category') #8 [internal function]: _update_term_count_on_transition_post_status('publish', 'publish', Object(WP_Post)) #9 in /www/wp-content/plugins/algoliasearch-wordpress-master/core/Registry.php on line 68

Woo Theme

Does the woo theme only work when instant search is on? Every time I turn instant search off, search results show in a blog format and not the way displayed on the woo theme image.

Error at install

PHP Fatal error: Call to a member function search() on null in /srv/media/www/prod/mgt-new/wp-content/plugins/algoliasearch-wordpress/AlgoliaPlugin.php on line 183

Error by activating plugin.

Fatal error: Uncaught exception 'Exception' with message 'AlgoliaSearch requires the CURL PHP extension.' in /var/www/html/edukart/wp-content/plugins/algoliasearch-wordpress-master/lib/algolia/algoliasearch.php:132 Stack trace: #0 /var/www/html/edukart/wp-content/plugins/algoliasearch-wordpress-master/core/AlgoliaHelper.php(16): AlgoliaSearch\Client->__construct('T265CTWUG6', '253ba4ae34e4d2b...') #1 /var/www/html/edukart/wp-content/plugins/algoliasearch-wordpress-master/AlgoliaPlugin.php(21): Algolia\Core\AlgoliaHelper->__construct('T265CTWUG6', '470b300485f3876...', '253ba4ae34e4d2b...') #2 /var/www/html/edukart/wp-content/plugins/algoliasearch-wordpress-master/algolia.php(32): AlgoliaPlugin->__construct() #3 /var/www/html/edukart/wp-admin/plugins.php(151): include('/var/www/html/e...') #4 /var/www/html/edukart/wp-admin/plugins.php(153): plugin_sandbox_scrape('algoliasearch-w...') #5 {main} thrown in /var/www/html/edukart/wp-content/plugins/algoliasearch-wordpress-master/lib/algolia/algoliasearch.php on line 132

Warning in AlgoliaPlugin.php / AlgoliaHelper.php / Pluggable.php file

Error on Following files:

  1. pluggable.php file - Warning: Cannot modify header information - headers already sent on line 1178
  2. AlgoliaHelper.php - Warning: in_array() expects parameter 2 to be array, string given on line 140 & 194.
  3. AlgoliaPlugin.php - Warning: in_array() expects parameter 2 to be array, string given on line 444.

Check Screenshot for more details.
screenshot from 2015-04-24 16 30 46

Add excerpt to the index

Please consider to add the excerpt back to the index by default.

It would be nice if a excerpt could be added to the index at the moment we have to do this manually by commenting in this line of code.

//$obj->excerpt = my_excerpt($data->post_content, get_the_excerpt());

Could you elaborate why this was commented out?

Cache

It looks like there is an issue with request cache since the object get modified

Fatal Error on saving UI configuration tab

Got some unexceptional error while saving the plugin. Pasting the exact error below.

Fatal error: Uncaught exception 'AlgoliaSearch\AlgoliaException' with message 'Operations quota exceeded, change plan to get more Operations.' in /home/edukart/public_html/alpha/wp-content/plugins/algoliasearch-wordpress-0.0.3/lib/algolia/algoliasearch.php:532 Stack trace: #0 /home/edukart/public_html/alpha/wp-content/plugins/algoliasearch-wordpress-0.0.3/lib/algolia/algoliasearch.php(408): AlgoliaSearch\Client->doRequest(Object(AlgoliaSearch\ClientContext), 'PUT', 'M77JEJ0MR1-3.al...', '/1/indexes/wpek...', Array, Array) #1 /home/edukart/public_html/alpha/wp-content/plugins/algoliasearch-wordpress-0.0.3/lib/algolia/algoliasearch.php(987): AlgoliaSearch\Client->request(Object(AlgoliaSearch\ClientContext), 'PUT', '/1/indexes/wpek...', Array, Array) #2 /home/edukart/public_html/alpha/wp-content/plugins/algoliasearch-wordpress-0.0.3/core/AlgoliaHelper.php(53): AlgoliaSearch\Index->setSettings(Array) #3 /home/edukart/public_html/alpha/wp-content/plugins/algoliasearch-wordpress-0.0.3/core/AlgoliaHelper.php(144): Algolia\Core\A in /home/edukart/public_html/alpha/wp-content/plugins/algoliasearch-wordpress-0.0.3/lib/algolia/algoliasearch.php on line 532

Error in extra-metas.php file

Encountered a error while tried to Configure here the attributes you want to include in your Algolia records in extra-metas.php file on line number 119, 224, 253, 264.
screenshot from 2015-04-24 16 18 50

jquery libraries within bundle.min.js

First of all, thank you for this plugin..I'm very excited by what you have put together here.

Once I activated the plugin, I'm getting an error within chrome dev tools
Uncaught Error: Syntax error, unrecognized expression: .asset.handle-lib/bundle.min.js.scripts

When I reviewed the bundle, I see that jquery, jquery ui, jquery touch punch are being loaded. Each of these is included within WP; however, WP uses different versions.

jQuery
WP (1.11.2) / Bundle (1.11.3)

jQuery UI
WP(1.11.4)/ Bundle(1.10.5)

TouchPunch
WP (0.2.2) / Bundle(0.2.2)

My site already is using jQuery and jQuery UI libraries (which I'm thinking is causing the error), and to avoid potential conflicts with other plugins, I do not want to dequeue those versions. As such, is there any way to get an extensions bundle.js that does not include those libraries and just add the jquery/jquery ui dependencies within the enqueue scripts function?

Thanks for any help/guidance you can provide on this.

Cannot save credential settings

Hey there guys,

I've been trying to get this working locally, but I've been having some issues. When I try to save the credentials for Algolia, it POSTs just fine, and the fields are populated when the POST request appears to have gone through correctly and 302'd the client back to the same config page. When I refresh this page, the values are all blank.

Any ideas what could be causing this or any potential solutions?

Having this issue on both Development and Staging

tested on PHP versions 5.5.18 and 5.6.2

Choosing the Autocompletion mode is misleading

When using the auto-completion mode, if a user press "Enter" instead of selecting a product/category he will be redirected to the default search results page of Wordpress. This one is rendered without Algolia, using the default search of Wordpress. That's misleading because the results are probably not the same than the one you saw while using the auto-completion menu.

Solution 1:

  • replace the "PHP/backend" search of Wordpress by Algolia.

Solution 2 (probably better):

  • not anymore either "auto-completion" OR "instant-search"
  • but rather "auto-completion" AND "instant-search" -> auto-completion menu would be displayed on all pages that are not the search results page; instant search on the results page.

How to develop Guided / Filtered Search

We want to generate the Guided Search which will fill ask user for Program type then Product Name and then fetch result. User can further drill down the search using Filters available on screen.

Taxonomies index

Since the merge of the Taxonomies & Attributes tabs, it's not clear whether the taxonomies are creating indices for the auto-completion menu.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.