PDA

View Full Version : Sending BaseParam with Store



rymoore9999
9 Nov 2008, 7:58 AM
I am using a JsonStore, and for certain reasons, I need to send the parameters as GET variables instead of POST. I am currently accomplishing this by using setting the 'method' property on a HttpProxy's connection:


var pxy = new Ext.data.HttpProxy({
url: urlStr
});
pxy.conn.method = 'get';

var store = new Ext.data.Store({
proxy: pxy,
...
});

When I do this, however, any BaseParams on my store are not passed to the GET request. How can I resolve this issue?

Thanks

devnull
9 Nov 2008, 9:04 AM
method can be specified in the HttpProxy options. http methods should always be given in upper case too:


var pxy = new Ext.data.HttpProxy({
url: urlStr,
method: 'GET'
});

var store = new Ext.data.Store({
proxy: pxy,
...
});

rymoore9999
9 Nov 2008, 4:23 PM
works, thanks!