WordPress.org

Forums

SearchAutocomplete
[resolved] Setting minLength and taxonomy types (7 posts)

  1. mikeen
    Member
    Posted 1 year ago #

    Hi,
    Tried to use the plugin, and it's great, but I'm not able to change the min length trigger, changed it in the admin panel, but it always triggers after 2 characters.

    Looks like in search-autocomplete.js it sets minLength: 2, with no regards to the options.

    The same happens with the taxonomies checkboxes, when either of them is checked it searches in all of the taxonomies, and not filtering only the types that are checked.

    And from looking at searchautocomplete.php, it looks that count( $this->options['autocomplete_taxonomies'] ) > 0 but not checking the returned terms are in this array.

    Would love to get your help and find out what I'm missing over there.

    http://wordpress.org/extend/plugins/search-autocomplete/

  2. Gabe Shackle
    Member
    Plugin Author

    Posted 1 year ago #

    Thanks for catching this! I'm pushing out an update this evening that will fix this bug.

  3. mikeen
    Member
    Posted 1 year ago #

    Cheers, thanks for fixing for minLength.

    What about the taxonomies options selection? Even when I'm checking only the 'Categories' taxonomy in the settings, it will display terms from both the Categories and Tags tables.

  4. Gabe Shackle
    Member
    Plugin Author

    Posted 1 year ago #

    Is this the same issue that you posted the separate thread about? If so, could you close this ticket?

  5. mikeen
    Member
    Posted 1 year ago #

    These are two different issues.

    This one is about the type of taxonomies being displayed - even when marking only one taxonomy in the settings, it will display terms from all of the existing taxonomies - no filtering of selected taxonomies occurs.

    The other is about posts not being shown by the autocomplete, when the posts are queried they are put into $resultsTerms, and right after it, $resultsTerms is being used for the terms.
    So on lines 124-129, when merging the two results, $resultsPosts is in fact empty.

    Thanks for your help for looking into this.

  6. Gabe Shackle
    Member
    Plugin Author

    Posted 1 year ago #

    I've pushed a version this evening that should fix this issue (2.0.6). Please upgrade and let me know if you experience any issues, thanks!

  7. mikeen
    Member
    Posted 1 year ago #

    Looks like it's working great now, thanks.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • SearchAutocomplete
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic