I used a frame to display https://www.yahoo.com from my Jetty Proxy 
Servlet. I can display this page in Frame, but once I run "((IFrameElement) 
element).getContentDocument()" in Java code and I got "Permission denied to 
access property 'document'" from a compiled cache.html. But I can use the 
same frame to display a file from same server like 
"http://127.0.0.1:82/Test.html. Once I run  "((IFrameElement) 
element).getContentDocument()" and I could get a Document value. I used 
Firebug to find the following html source like:

<iframe class="gwt-Frame gwt-TabLayoutPanelContent" src="
http://127.0.0.1:82/Test.html"; style="position: absolute; left: 0px; top: 
0px; right: 0px; bottom: 0px;">


<iframe class="gwt-Frame gwt-TabLayoutPanelContent" src="
http://127.0.0.1:82/proxy?https://www.yahoo.com/"; style="position: 
absolute; left: 0px; top: 0px; right: 0px; bottom: 0px;">


I don't kown what is wrong. They seem to be from the same origin source. 
May Jetty Proxy Servlet not work as expected?

This project is due in two days. Please help out of this issue.

Many thanks,

Leon

On Thursday, February 16, 2012 4:19:35 AM UTC-5, Thomas Broyer wrote:
>
> The error happens in loadModule, so your code hasn't yet been called 
> (except possibly the onModuleLoad), or at least the error is not about $doc 
> in JSNI, because the exception comes from displayErrorGlassPanel. This 
> method tries to access the outer-most window object [1], and it's failing 
> here most probably because of a Same-Origin Policy violation.
> There are two possible causes to this:
>
>    - your GWT app runs in a frame within a document from a different 
>    origin (e.g. GWT app loaded from server1.com in a frame of a document 
>    loaded from server2.net; it could also be as small a difference as 
>    www.server.com vs. server.com)
>    - you're loading the HTML host page out of the file-system rather than 
>    served through HTTP (would be really strange for a DevMode session though)
>
>
> [1] 
> http://code.google.com/p/google-web-toolkit/source/browse/trunk/dev/core/src/com/google/gwt/core/ext/linker/impl/hosted.html#170
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

Reply via email to