2048 Error Actionscript
Contents |
here for a quick overview of the site Help
Error #2048 Security Sandbox Violation Flash
Center Detailed answers to any questions you might have error #2048 security sandbox violation cannot load data from Meta Discuss the workings and policies of this site About Us Learn more about
Flash Security Error 2048
Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Flex - Security Sandbox violation - ERROR#2048 up vote 3 down vote favorite 1 So if i put -http://xxx.xx.xx.x/website/website.html and try to use an HTTPService with in the swf to contact -https://yyy.yy.yy.y/resources/script, I get the sandbox error. If I put -https://yyy.yy.yy.y/crossdomain.xml in the browser and access it everything in the crossdomain file looks fine. wWen i go back and try to use the HTTPService from -http://xxx.xx.xx.x/website/website.html everything now works until i close the browser which i assume clears the cache. ********crossdomain.xml*********
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, http://stackoverflow.com/questions/5157089/flex-security-sandbox-violation-error2048 helping each other. Join them; it only takes a minute: Sign up as3 Error #2048: Security sandbox violation when trying to connect through socket up vote 1 down vote favorite I have a SWF file embedded in a PHP web application. All local and on my system. I want to make a socket connection from my SWF http://stackoverflow.com/questions/30503550/as3-error-2048-security-sandbox-violation-when-trying-to-connect-through-socke to localhost:4242 (which is an eye tracker api). When I run SWF using flash player everything works fine. But when I run it from browser I get: Security Error: [SecurityErrorEvent type="securityError" bubbles=false cancelable=false eventPhase=2 text="Error #2048: Security sandbox violation: http://localhost/graph/assets/swf/Graph.swf cannot load data from http://localhost:4242."] I added crossdomain.xml to my local web server (easy php) like this:
in domain A is trying to access http://thong-vu.blogspot.com/2011/03/flash-error-2048-security-sandbox.html a swf from domain B, and it does not like it... I have a few solutions to this problem. 1) add a cross domain xml on to the root directory of your domain. You can see example here. 2) load the swf using error #2048 byte array. You can see the example here. 3) add "Security.allowDomain(...domains)" to the swf you are trying to access. Here is a code to achieve solution #3. public class IHateDomainIssues extends Issues { pubic function IHateDomainIssues():void { // allow all domain error #2048 security Security.allowDomain("*"); // TODO: your loading swf code } } There you have it. Feel free to ask if you have questions. Related Links: cross domain loading-files-using-urlstream Adobe ActionScript Language Reference Posted by Thong Vu at 9:36 PM Email ThisBlogThis!Share to TwitterShare to FacebookShare to Pinterest Labels: Flash, Flash 103: Advanced, Flash 104: Errors No comments: Post a Comment Newer Post Older Post Home Subscribe to: Post Comments (Atom) About Me Thong Vu United States Flash.Actionscript.AS3.Adobe.Photoshop.Vietnamese.Food. View my complete profile Labels AsDoc (2) Eclipse (3) Fact or Fiction (1) Flash (17) Flash 101: Beginner (5) Flash 102: Intermediate (3) Flash 103: Advanced (5) Flash 104: Errors (6) Flash Image (4) Flex Builder (2) Food (1) Random (1) Total Pageviews Awesome Inc. template. Powered by Blogger.