I’m not an expert at this by any
stretch. The security sandbox violation when dealing with images/movies
generally occurs because the SWF that did the loading (myserver.com/index.mxml)
tries to access properties of the loaded movie (otherserver.com/someImage, and
yes I realize it may not be a SWF). I’m not sure why properties you’d
be trying to access though, maybe depth swapping or something? Maybe the Flex
app does it on its own. I wonder if Manish ran into this with the map example J As for it working with XML and not with
RemoteObject, that does strike me as strange. The only thing I can think of would
be that somehow establishing a connection to your source server prevents the
SWF from thinking that it should be allowed to contact the other server. Do you
own the other server? Any chance you could try putting a crossdomain.xml file
on there (see technotes for info on crossdomain). Sorry, not very useful I know, Matt From: Kristopher
Schultz [mailto:[EMAIL PROTECTED] I'm trying to load some images from a different domain
than the one my Flex app lives on. When I do, the debugger prints out a bunch
of errors like this: *** Security Sandbox Violation *** SecurityDomain 'http://myserver.com/index.mxml?debug=true'
tried to access incompatible context 'http://otherserver.com/someImage?wid=30' (Note, the image is dynamically generated and the URL
should not include ".jpg") Despite the errors, my images still seem to load in
successfully, both through the Flex Builder IDE and when viewed directly in IE.
Or so I thought. The weird thing I've discovered is that if my image paths
are brought into my Flex app via an XML file, then I do get the errors above,
but the images do load successfully. However, if my image paths come in as a
result of a remote object call, I get the same errors and my images DON'T load
successfully. I've double checked the exact path's that are being used in both
situations by tracing out the path immediately before it is used as the value
for the "source" property of the <mx:Image> tag and it is
EXACTLY the same in both cases. So I have questions. First, why do I get those error
messages? Secondly, if there really is a security sandbox violation, why do the
images load successfully under the conditions I mentioned above? And finally,
how do I prevent these violations from occurring in the first place? Thanks for any insight you can provide. Kris -- Kristopher Schultz Developer Resource Interactive p: 614.410.2123
Yahoo! Groups Links
|
- Re: [flexcoders] Security Sandbox Violation when loadi... Matt Chotin
- Re: [flexcoders] Security Sandbox Violation when ... Manish Jethani
- RE: [flexcoders] Security Sandbox Violation when ... Kristopher Schultz
- RE: [flexcoders] Security Sandbox Violation when ... Dimitrios Gianninas
- RE: [flexcoders] Security Sandbox Violation when ... Matt Chotin