onkeypress with filter function

im using the filter for the grid for a date columm:
dhxGrid.attachHeader("#rspan,#text_filter");

the date format is: DD-MM-YYYY, how can i make it that when you type it in a different format, it automaticly changes to the right format?

for example:

DDMMYYYY -> DD-MM-YYYY
DD-MM-YYYY -> DD-MM-YYYY
DDMMYY -> DD-MM-YYYY
DD-MM-YY -> DD-MM-YYYY

so when you type the date, and leave the -'s out, it fills it in automaticly after each keypress…

It can be done only with custom filter in the header. You can attach onblur or any other event to the custom input in the header and change it’s value in necessary way

could you please give me an example of how to do this?
thans in advance!

Tutorial of attaching custom content in the header is available here docs.dhtmlx.com/doku.php?id=dhtm … er_extra&s[]=custom&s[]=header

grid.attachFooter(“A,,C”);

function foramtDate(){
//your custom code here
}

How can i make this function, that it still filters the result after a input?