简体   繁体   中英

jQuery Datatables - match filtering words

I am using jQuery datatables and was hoping someone knew how to do this.

We have items in the database listed as 4x4 and 4wd. I would like it to also retrieve 4wd when I type in 4x4 and visa versa.

Thanks for your help in advance.

Andy

One solution will be to have a hidden column (see bVisible ) and add the alternate description in that column. (In your case, where the result is 4x4 then in the hidden column it would be 4wd and the other way around). So when you search you will get both results

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM