You need to implement the qx.data.store.IStoreDelegate to configure your request
and pass it to the Json constructor. Like this:
var delegate = {
configureRequest : function(request) {
request.set({
"method" : "POST",
"requestData" : { "serviceToUseOnServer" : "articles",
"argument1" : "xxx" }
});
},
};
var store = new qx.data.store.Json(url, delegate);
Since you're using Json, the request type used is qx.io.request.Xhr.
See the Json API docs:
http://demo.qooxdoo.org/current/apiviewer/#qx.data.store.Json
--Roman.
On 02/23/2012 05:59 PM, totty wrote:
> In the tutorial
> http://manual.qooxdoo.org/1.6.x/pages/tutorials/tutorial-part-3.html they
> only show this:
>
> var url = "http://api.twitter.com/1/statuses/public_timeline.json";
> this.__store = new qx.data.store.Jsonp(url, null, "callback");
>
> But I would need to communicate with my own server, so I've made some
> changes: (url and Jsonp to Json)
>
> var url = "http://127.0.0.1:8000/";
> this.__store = new qx.data.store.Json(url);
>
> But I would need to be able to send some information to the server when the
> store make the request like:
>
> {serviceToUseOnServer: 'articles', argument1: 'xxx'}
>
> This is like a POST request, but I don't really know how to send that data
> to the server using qooxdoo's Store models. Please don't tell me to use GET
> and encode all that data in an url.
>
> Thanks (:
>
> --
> View this message in context:
> http://qooxdoo.678.n2.nabble.com/How-to-use-Qooxdoo-s-Stores-to-request-an-ajax-response-with-a-POST-tp7312461p7312461.html
> Sent from the qooxdoo mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> Virtualization& Cloud Management Using Capacity Planning
> Cloud computing makes use of virtualization - but cloud computing
> also focuses on allowing computing to be delivered as a service.
> http://www.accelacomm.com/jaw/sfnl/114/51521223/
> _______________________________________________
> qooxdoo-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel