PDA

View Full Version : Dynamic set the url proxy of a DataStore



steve1964
17 Sep 2010, 9:40 AM
Is it possible to dynamic change the proxy url config of a DataStore?


var peopleStore = new Ext.data.Store({
model : 'peopleModel',
autoLoad : true,
proxy : {
type : 'ajax',
url : 'php/people.php?username=test&distance=100',
reader : {
type : 'json',
root : 'people'
}
}
});

this for example is the initial setup of the Datastore, i want to change the url to pass another distance for example and update the datastore

steve1964
17 Sep 2010, 10:08 AM
Sorry, i solved...


store.proxy.url = 'foo';