Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 10-10-2007, 09:07 AM   #1
Strifedk
Registered User
 
Join Date: Aug 2006
Posts: 7
Default setMask, Sandbox offline/online problem

Hi everyone...

I hope there is someone who can demystify and solve the problem I'm having.

I would like to load flashbanners in to other movies, like this:
Movie on one domain loads a movie from another domain.
Locally I get a Sandbox Security Violation notice

*** Security Sandbox Violation ***
SecurityDomain 'http://mini6.mcbtest.dk/cultbanner.swf' tried to access incompatible context 'file:///Z|/Flash%20Skin%20All/web/bannerTest.swf'

and when i add this to the top of my script it goes away
Code:
System.security.allowDomain("*")
So thats all fine, but here's the problem, when I upload it to a server, my mask will not work.

The movie can be seen here:
http://mini5.mcbtest.dk/bannertest.swf

And my script looks like this:
Code:
textPadding = 20 
bannerWidth = 174 
bannerHeight = 62 
textBGColor = 0x000000 
textBGAlpha = 40 
rightBoxWidth = 174 


this.createEmptyMovieClip("sideWindow",this.getNextHighestDepth()) 
     with (sideWindow) { 
     beginFill(textBGColor, textBGAlpha); 
     moveTo(0, 0); 
     lineTo(bannerWidth + (textPadding * 2), 0); 
     lineTo(bannerWidth + (textPadding * 2),bannerHeight + (textPadding * 2)); 
     lineTo(0,bannerHeight + (textPadding * 2)); 
     endFill(); 
} 
this.createEmptyMovieClip("bannerContainer",this.getNextHighestDepth()) 
bannerContainer._x = textPadding 
bannerContainer._y = textPadding 
        
bannerContainer.createEmptyMovieClip("entityClip",bannerContainer.getNextHighestDepth()) 
bannerContainer.createEmptyMovieClip("bannerMask",bannerContainer.getNextHighestDepth()) 
with (bannerContainer.bannerMask) { 
     beginFill(0x00FF00, 50); 
     moveTo(0, 0); 
     lineTo(bannerWidth, 0);    
     lineTo(bannerWidth,bannerHeight); 
     lineTo(0,bannerHeight); 
     endFill(); 
} 
        
bannerLoader = new MovieClipLoader(); 
oListener = new Object(); 
oListener.onLoadStart = function():Void  { 
     trace("start") 
} 
oListener.onLoadProgress = function():Void  { 
     trace("progress") 
} 
oListener.onLoadComplete = function():Void  { 
     trace("complete") 
} 
oListener.onLoadInit = function(mHolderClip:MovieClip):Void  { 
     mHolderClip.setMask(mHolderClip._parent.bannerMask) 
     createContent() 
     trace("init") 
}; 
bannerLoader.addListener(oListener); 
bannerLoader.loadClip("http://mini6.mcbtest.dk/cultbanner.swf", bannerContainer.entityClip); 
        
createContent = function(){ 
                        
     bannerContainer.bannerMask.onRelease = function(){ 
          trace("click") 
     } 
}
Hope somone can help, thanks
Strifedk is offline   Reply With Quote
Old 10-10-2007, 11:51 AM   #2
Strifedk
Registered User
 
Join Date: Aug 2006
Posts: 7
Default

Solved it...

System.security.allowDomain("*")

needs to be in the movie which is beeing loaded in...
Strifedk is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
setMask problem. Maybee a bug? maxgrafx ActionScript 1.0 (and below) 1 08-11-2005 04:51 AM
fade in, fade out movieClip button problem... tykomusic ActionScript 2.0 2 06-03-2005 04:17 PM
Flash Number type and c# float and decimal types. Convertion problem within Flash. maglez ActionScript 2.0 2 06-02-2005 05:14 PM
setMask problem black ActionScript 2.0 4 02-18-2005 04:18 AM
Macromedia Central CyanBlue ActionScript 1.0 (and below) 13 08-01-2003 09:05 PM


All times are GMT. The time now is 12:58 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.