سؤال

i use this code - live example:

http://live.datatables.net/zuzimeq/1/edit

But i can only enter a number without a '/' or '.' or something like that. So how can i filter the date column?

Thanks for helping..

هل كانت مفيدة؟

المحلول

Your current function is parsing your entry and look for age field. It needs to be

var min = $('#min').val();
var max = $('#max').val();
var date =  data[4]; // use data for the age column

if ( ( min == '' && max == '' ) ||
     ( min == '' && date <= max ) ||
     ( min <= date && '' == max ) ||
     ( min <= date && date <= max ) )
{
    return true;
}
return false;

http://live.datatables.net/benixip/3/edit

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top