FreakBoy a écrit : > If I tokenize the values then it searches for anything with “any” of > the words, not for anything with both. > > Is there a way to have it do a search for “TermA” AND “TermB” ?
Yes, but the +tokens+ option is not designed for this: if you tokenize with whitespace, for instance, you're basically completing only the current (last-edited) token, not completing based on all tokens. The default algorithm for local match, which implements partial and full search, does not suit your needs (split on whitespace and match any). That's not its doc'd behavior. If you need such a behavior, you'll have to pass a custom +selector+ option, which will have to re-implement any default match option you were passing. Check Scripty's code in Autocompleter.Local, and how its +setOptions+ method defines the default +selector+ option for clues. 'HTH -- Christophe Porteneuve aka TDD [EMAIL PROTECTED] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
