List.js + checkbox values (jsfiddle)

HI,

I have a list with checkboxes, and I use list.js to filter between them.

My problem is that if i check one of the boxes, then i filter and check another, the other one isn’t in the dom anymore and hence, the value is lost.

I tried using a textarea that the checked values are sent to, but same thing there, if one of the checked boxes isnt visible when i update the value is gone.

I have a fiddle here: https://jsfiddle.net/jbjvehmz/26/

Anyone know how I can solve this? keeping the values of checked boxes even if i “filter them away” ?

It seems that when you perform the search, it’s reloading the page and showing you a completely fresh version of the page. Perhaps that accounts for why things seem to be lost.

I see. Well i skipped the library and went with another solution just hiding elements when searching instead of removing them from the dom.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.