Search on listview works only 5 seconds because of AJAX reloads the content
Hi. I have a listview loaded via ajax.It uses the data-filter="true" for search.
The content updates every 5th second using setTimeout. So the search field only works for 5 sec.
How can I get around this?
heres some of my function
- function showUser(str)
- {
- curevent = str;
- $('#tests').load('getuser.php?q='+str, function(){$('#tests').listview('refresh');});
- $('#eventvalue').val(str);
- setTimeout(function(){showUser(curevent);}, 5000);
- }