Cross Domain issue with images


i have image tag <mx:image/> setting source product images. .swf on http side of website , images on https side. getting error:

 

securityerror: error #2122: security sandbox violation: loader.content: http://www.mydomain.com/masonic.swf cannot access https://www.mydomain.com/masonic_images/13_red_d2-mas72479bl_red.jpg. policy file required, checkpolicyfile flag not set when media loaded.

at flash.display::loader/get content()

at smoothimage/http://www.adobe.com/2006/flex/mx/internal::contentloaderinfo_completeeventhandler()

i don't know how set cross-policy flag on image component. googled how set cross-domain-policy file , found tutorial said add this:
var context:loadercontext = new loadercontext();
// set check policy flag in loader context
context.checkpolicyflag=true;
loader.load(request,context);
but flex builder giving me 2 errors this, call undefined property checkpolicyflag static class loadercontext, , loader.load expects no more 1 arg.
so can please tell me can display images secure side?
thanks!!!

ok followed tutorial , did said: http://www.damienking.net/tutorial-using-remotely-hosted-images-flex

 

and getting new error:

 

securityerror: error #2123: security sandbox violation: loader.content: http://www.mydomain.com/masonic.swf cannot access https://www.mydomain.com/masonic_images/12_red_d2-mas60338bl_red.jpg. no policy files granted access.

at flash.display::loader/get content()

at smoothimage/http://www.adobe.com/2006/flex/mx/internal::contentloaderinfo_completeeventhandler()

this crossdomain.xml looks like:
<?xml version="1.0"?>
<!doctype cross-domain-policy system "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
   <allow-access-from domain="*" />
</cross-domain-policy>
what doing wrong?????



More discussions in Flex (Read Only)


adobe

Comments

Popular posts from this blog

Flip address is out of range arduino uno r3

Arduino Uno not uploading

Indesign and MathType fonts