I have image upload field like
{
xtype: 'textfield',
fieldLabel: 'Image',
labelSeparator: '',
name: 'newPic',
id:'newPic',
anchor:'100%',
inputType: 'file',
allowBlank: false
}
When i submitting form, Im encoding all form data in a json object.All textfields data are coming in json object but not image is passing to server side . How to pass image so as to save it in server side
var form=Ext.getCmp('empPersonal');
var formdata=Ext.JSON.encode(form.getValues());
alert(""+formdata);
if(Ext.getCmp('empPersonal').getForm().isValid()) {
Ext.Ajax.request({
url:'ws/employees/create/'+formdata,
No comments:
Post a Comment