I'm ExtJS newbie. I need to send the contents of a ExtJS Textarea to the backend server for saving (autosave facility) as the user types in. How do I buffer the contents and push the buffer to the server after some threshold value. A code sample would greatly help me. So far, I've done as below:
items: [{
xtype: 'textarea',
id: 'notes',
anchor: '100%',
height: 270,
msgTarget: 'under',
fieldLabel: 'Note',
enableKeyEvents: true,
listeners: {
'keyup': function(textarea, event) {
var v= textarea.getValue();
Ext.Ajax.request({
url: 'buffernote.action',
params: {value: v}
})
}
}
}
}]