riklomas / quicksearch

A jQuery plugin for searching through tables, lists, etc quickly
http://www.lomalogue.com/jquery/quicksearch/
680 stars 261 forks source link

Support for multiple selectors? #8

Open patcon opened 13 years ago

patcon commented 13 years ago

Any chance of adding the ability to search for multiple selectors. I'm trying to make this into an exposed filter for the Drupal Views module, and adding a common class to each cell isn't the most elegant solution. Is it utterly out of scope to allow an array?

Anyhow, great great great plugin by the way! Thanks very much!

shadowhand commented 13 years ago

The following change could be inserted to fix this without breaking backwards compatibility:

if (typeof options.selector != 'array') {
    options.selector = [options.selector];
}

Inserted around line 35, plus using an apply() call would make this possible.

patcon commented 13 years ago

Thanks shadowland. I'll give it a go when I put this into a future project!