On Dec 16 2009, 12:49 pm, joe <[email protected]> wrote: > yeah it looks like the link was butchered when I send the post. > > http://www.gwtapps.com/doc/html/com.google.gwt.http.client.html > > I have tried what you are using. However, after looking into the > problem more I see that Same Origin Policy seems to be my issue. It > looks like without using JSONP I can not call my self hosted C# WCF > application. This is due to the port miss match (Jetty server runs on > 8888 and my self hosted WCf app runs on 80) which violates S.O.P. > > According to Google's docs I can not do this without some 'hack' on > the GWT > side.http://code.google.com/webtoolkit/doc/1.6/FAQ_Server.html#How_can_I_d... > > I have looked into using JSONP with WCF but I have been unable to > locate a way to send a pure JSONP object to GWT. The only thing I have > been able to do it send a string that holds my JSONP string. so there > are leading and trailing ". I would assume that GWT won't like this. > > So right now I have no other option but to write a GWT back-end proxy > so that GWT front end can call my C# app to request data, unless > anyone has any ideas. > > Thank you >
We had a similar problem, and we got JSONP working with GWT. Unfortunately, JSONP + GWT does not provide the desired results where concurrency is concerned (i.e. we get responses in the order the requests were sent -NOT the order in which responses are received) To circumvent this, I've implemented CORS on our app server, and it works with XSS requests in both devmode and hosted mode: http://www.w3.org/TR/access-control/ This is supported in FF 3.5+ and IE8. Note that IE8 asks the user every time a cross-site request is sent. It's possible this can be circumvented, but I did not investigate further. We only care about XSS support for devmode - the deployed product will be hosted by the same web server. Hope this helps, -- Richard Kolkovich http://www.sigil.org PGP Key: 0x9E54EF59 (http://pgp.mit.edu) -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
