PDA

View Full Version : Problem with empty $POST



Julia_Rakitina
13 Aug 2012, 11:01 PM
Hello!

I have problem, driving me crazy :(

First it is an editable grid (plugins: [cellEditing],) with this store (store: sql,)


var sql = Ext.create('Ext.data.Store', { model: 'SQL',
groupField: 'project',
proxy: {
type:'ajax',
api: {
read: 'data/showText.php', // Called when reading existing records
update: 'data/saveRollout.php' // Called when updating existing records
},
actionMethods: {
read : 'GET',
update : 'POST'
},
reader: {
type: 'json',
root: 'data'
},
writer: {
type: 'json'
}
},


autoSync: true,
autoLoad: true
});

Everything going excellent until it POST to saveRollout.php JSON and a can see in Firebug that it really posts


{"projectId":0,"project":"","taskId":0,"description":"","january":0,"february":0,"march":10,"april":0,"may":0,"june":0,"july":0,"august":0,"september":0,"october":0,"november":0,"december":0,"id":null}

But on server-side $_POST returns NULL. Where is my JSON? Please help.

evant
13 Aug 2012, 11:16 PM
http://php.net/manual/en/reserved.variables.httprawpostdata.php

Julia_Rakitina
13 Aug 2012, 11:27 PM
Many thanks! I found my JSON :-) !!!