gonuldas / gwtupload

Automatically exported from code.google.com/p/gwtupload
Other
0 stars 0 forks source link

uploader.getServerRawResponse().getMessage() returns null if CORS is being used #187

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

I use OnFinishUploaderHandler() and read the message from the server:

            public void onFinish(IUploader uploader) {
                GWT.log("server message ="
                        + uploader.getServerMessage().getMessage());
            }

This works fine, but if I use CORS, fill get uploaded successfully and progress 
bar indicates "Done",
but uploader.getServerRawResponse().getMessage() returns null.

I use gwtupload-1.0.0.jar

Original issue reported on code.google.com by to...@ekc.lt on 19 Jan 2014 at 4:06

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I found this:

SubmitCompleteEvent.getResults() always returns null
https://groups.google.com/forum/#!topic/google-web-toolkit/x5tgUCzx2UE

Original comment by to...@ekc.lt on 20 Jan 2014 at 2:00

GoogleCodeExporter commented 8 years ago
P.S. This is with GWT 2.5.1 version

Original comment by to...@ekc.lt on 20 Jan 2014 at 11:38

GoogleCodeExporter commented 8 years ago
I think this issue could be closed as not gwtupload problem.

I looked at the source of FormPanelImpl.java (in 
com.google.gwt.user.client.ui.impl).

There is more useful info here:
http://blog.cakemail.com/the-iframe-cross-domain-policy-problem/
https://developer.mozilla.org/en-US/docs/Web/API/window.postMessage?redirectloca
le=en-US&redirectslug=DOM%2Fwindow.postMessage

Original comment by to...@ekc.lt on 21 Jan 2014 at 1:06

GoogleCodeExporter commented 8 years ago
Last  gwtupload versions support CORS, but you have to set the corsDomainsRegex 
in your servlet configuration in order to it sends the apprppriate CORS headers:

https://code.google.com/p/gwtupload/source/browse/samples/src/main/webapp/WEB-IN
F/web.xml

Original comment by manuel.carrasco.m on 6 Mar 2014 at 5:00

GoogleCodeExporter commented 8 years ago

Original comment by manuel.carrasco.m on 2 Apr 2014 at 8:36

GoogleCodeExporter commented 8 years ago

Original comment by manuel.carrasco.m on 27 Apr 2014 at 9:54