Not sure why that is a surprise. The simplest thing I can do in qooxdoo I've already done but unfortunately that is of little use to me in the project I'm working to get qooxdoo integrated into :)
index.php from the PHP rpc implementation which acts as a translator and dispatcher of requests for servicing and executing RPC calls is rejecting the request before it ever gets to looking at the format because qooxdoo is sending the request using the HTTP method OPTIONS, as opposed to the more typical HTTP methods of GET and POST. To know what I mean by that you would need to know more about the HTTP protocol. The PHP rpc implementation basically has a code block in it that says: if this is a post request... do some processing of request else if this is a get request (and a few other things)... do some other processing of request else throw an error // and this is what is happening OK, I will go checkout RpcExample and set it up. What's up with the source forge repo for qooxdoo-contrib? All the links in the documentation point here: http://sourceforge.net/projects/qooxdoo-contrib/files/ and the only thing there is RpcPerl-0.1.zip and a couple other browsable trees for HtmlArea and such. Not even close to the qooxdoo-contrib repo. I was fortunate enough to find an SVN path in the mailing list archives so I did checkout https://qooxdoo-contrib.svn.sourceforge.net/svnroot/qooxdoo-contrib Seem like not having releases of qooxdoo-contrib readily available without svn checkout makes the latest releases of the contributed code less accessible. Jared Gene Amtower wrote: > JB, > > Surprisingly, you say you want to "start with something super simple" > but in my experience, RPC implementations are not the simplest thing > you can do in Qooxdoo. So, I think you're trying to learn how to use > Qooxdoo by jumping into the middle of the learning curve. I'm betting > that you're going to get frustrated very quickly. > > In this case, Index.php is replying that "you didn't send me a valid > RPC request" in your remote call - it doesn't just respond to normal > http requests, as it expects a specific request message format. I > also don't know what you mean by "OPTIONS" instead of POST or GET. > > As Derrell said, you really should download the RPCExample > contribution and verify that it works with your RPC-PHP server - it's > bound to be much easier than trying to add RPC methods to the Hello > World app, as both the client and remote methods are already created > for you. > > Once it's working, you can look at how it's written to learn more > about configuring RPC calls, as you're going to need to write your own > server-side methods to match what you're doing in your client-side > AJAX methods. RPCExample is one of the best ways to see how to write > Ajax code for RPC-PHP - learn by example rather than building from > scratch. > > Step back and try that approach and please let us know if you have > trouble getting RPCExample to work after giving it a try. > > HTH, > > Gene > > On Sun, 2009-10-18 at 09:21 -0600, JB wrote: >> I finally figured out what was going on with my app. I'm using the PHP >> rpc implementation in qooxdoo-contrib. The request goes the server, >> gets picked up by index.php but because the method used is "OPTIONS" and >> not POST or GET, index.php is replying with the following: >> >> JSON-RPC request expected; service, method or params missing<br> >> >> But in my App I see: >> Async(13) exception: Transport error 0: Unknown status code >> >> The 13 in the parens up there keeps incrementing each time I hit the >> buttons. What the heck is up with that? App code follows: >> >> var button1 = new qx.ui.form.Button("Send Rpc Request", >> "simwebui/test.png"); >> var rpc = new qx.io.remote.Rpc(); >> var mycall = null; >> //var container = new qx.ui.container.Composite(new >> qx.ui.layout.Basic()); >> >> // Document is the application root >> var doc = this.getRoot(); >> >> // Add an event listener >> button1.addListener("execute", function(e) { >> button1.setEnabled(false); >> var rpc = new qx.io.remote.Rpc(); >> rpc.setTimeout(10000); >> rpc.setUrl("http://192.168.10.180/services/"); >> rpc.setServiceName("qooxdoo.test"); >> >> // call a remote procedure -- takes no arguments, returns a string >> var that = this; >> this.RpcRunning = rpc.callAsync( >> function(result, ex, id) >> { >> that.RpcRunning = null; >> if (ex == null) { >> alert(result); >> } else { >> alert("Async(" + id + ") exception: " + ex); >> } >> button1.setEnabled(true); >> }, >> "echo.blabla"); >> >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference >> _______________________________________________ >> qooxdoo-devel mailing list >> qooxdoo-devel@lists.sourceforge.net >> <mailto:qooxdoo-devel@lists.sourceforge.net> >> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel >> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > qooxdoo-devel mailing list > qooxdoo-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel > ------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ qooxdoo-devel mailing list qooxdoo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel