Centering An Externally Loaded Swf.
Hello all. Why i post this is because i have/had problems with centering an externally loaded swf into a full browser flash (or atlest i think i got it full browser)it used to look like thishttp://www.consector.se/test/full2.htmlthe fla. is here http://www.consector.se/test/full2.flait uses this codeCode: stop();Stage.align = "TL";Stage.scaleMode = "noScale";stop ();// initiate postitions and scaling values for objectsholder_main._y = Stage.height /2;holder_main._x = Stage.width /2;holder_player._x = Stage.width - holder_player._width;coordinates._y = Stage.height - coordinates._height;coordinates._x = 0;// end initial position settingholder_main.scaleMode = "noScale";//create a listner that checks to see if the browser window is resizedsizeListener = new Object();sizeListener.onResize = function() { // change movieclip properties when the window is resized. holder_main._y = Stage.height /2; holder_main._x = Stage.width /2; holder_player._x = Stage.width - holder_player._width; coordinates._y = Stage.height - coordinates._height; coordinates._x = 0;};Stage.addListener(sizeListener);var mcl:MovieClipLoader = new MovieClipLoader();var mclL:Object = new Object () ;var aboutL:Boolean = false; //Create a boolean variablemclL.onLoadProgress = function(target,loaded,total) { var percentLoaded = Math.round((loaded/total) * 100); mcl_bytes.text = "loaded " + loaded + " of " + total + " bytes"; mcl_preloader_bar._xscale = percentLoaded; }mclL.onLoadInit = function() { mcl_preloader_bar._visible = false; mcl_preloader_stroke._visible = false; mcl_bytes.text = "";}mcl.addListener(mclL);mcl.loadClip("MP3Player.swf",holder_playe);mcl.loadClip("home.swf",holder_main);home_btn.onRelease = function () { mcl.loadClip("home.swf",holder_main);}about_btn.onRelease = function () { // Create an 'if' statement to check whether the mc has loaded before: if (aboutL == false) { loader._visible = true; aboutL = true; // set the boolean value to true } mcl.loadClip("about.swf",holder_main); } pictures_btn.onRelease = function () { // Create an 'if' statement to check whether the mc has loaded before: if (aboutL == false) { loader._visible = true; aboutL = true; // set the boolean value to true } mcl.loadClip("pictures.swf",holder_main);}this.onMouseMove = function (){ coordinates.xPos = Math.floor(_xmouse); coordinates.yPos = Math.floor(_ymouse); updateAfterEvent();}so i changed a little so now it looks like this.http://www.consector.se/test/full1.htmlthe fla. is here. http://www.consector.se/test/full1.flai changed this partCode: // initiate postitions and scaling values for objectsholder_main._y = (Stage.height /2) - (holder_main._height /2);holder_main._x = (Stage.width /2) - (holder_main._width /2);holder_player._x = Stage.width - holder_player._width;coordinates._y = Stage.height - coordinates._height;coordinates._x = 0;// end initial position settingholder_main.scaleMode = "noScale";//create a listner that checks to see if the browser window is resizedsizeListener = new Object();sizeListener.onResize = function() { // change movieclip properties when the window is resized. holder_main._y = (Stage.height /2) - (holder_main._height /2); holder_main._x = (Stage.width /2) - (holder_main._width /2); holder_player._x = Stage.width - holder_player._width coordinates._y = Stage.height - coordinates._height coordinates._x = 0};Stage.addListener(sizeListener);//even the carousel centers pretty good (i fiddled with something in there to so im not sure that the tutorial code will center untouched)only thing i dont like right now is that i most cases when rezising the browser the loaded swf jumps a little bit,,, any ideas?sorry for my bad code arrangement.
General Flash
Posted on: Sat Feb 17, 2007 6:06 pm
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Externally Loaded SWF Not Centering
Hi all,
I'm having yet another problem with an externally loaded movie. The photo scroller movie shows up fine when you get to the Artwork section of my site but it doesn't appear centered like I want to. I tried moving the container clip in the FLA file and that worked out ok. I can see that the external movie is centered fine. However, when I view the updated movie on the internet, the external movie appears way off.
Help!!!!! This is making me mad.
Centering Externally Loaded Jpeg
Trying to load and center different size externally loaded jpegs. It flashes "out of place" then centers quickly. I'm trying to keep it invisible until it's fully centered. I'm under a deadline so any quick help is greatly appreciated.
Here's what I got:
in the actions layer:
function preloadF() {
if (_root.empty_mc.getBytesLoaded() == _root.empty_mc.getBytesTotal()) {
onEnterFrame = function () {
if ((empty_mc._x=picContainerBack._x+(picContainerBac k._width-empty_mc._width)/2) && (empty_mc._y=picContainerBack._y+(picContainerBack ._height-empty_mc._height)/2)) {
clearInterval(preloadI);
delete (this.onEnterFrame);
empty_mc._alpha = 100;
} else {
empty_mc._x = picContainerBack._x+(picContainerBack._width-empty_mc._width)/2;
empty_mc._y = picContainerBack._y+(picContainerBack._height-empty_mc._height)/2;
}
};
}
}
on my button:
on (rollOver) {
_root.empty_mc._alpha = 0;
preloadI = setInterval(preloadF, 100);
_root.empty_mc.loadMovie("largeImages/image01.jpg");
}
What am I doing wrong or need to add?
Centering Externally Loaded Text
I have a dynamic text box with externally loaded text. I want the text to be centered in the box but i cant seem to figure it out. im pretty new at this so ive been going through loads of tutorials to get this website up.
so is there a code i need to use for the text box or do i need to put a code on my txt document???
im using this code for the text box:
myLoadVar = new LoadVars();
myLoadVar.load("photos.txt");
myLoadVar.onLoad = function(success) {
if (success == true) {
output.variable = "photos";
output.htmlText = myLoadVar.photos;
}
};
and the instance name for the dynamic text box: output
thanks in advance
www.platinumcollisioncenter.net
Externally Loaded Text Prob In Externally Loaded Swf
hi.
so i have a swf that has externally loaded text in it that is being loaded into another swf. the text loads properly when the swf is opened by itself but when the swf is loaded into my main movie the text ceases to appear
my code to load the text is
loadText = new LoadVars();
loadText.load("dates.txt");
loadText.onLoad = function() {
event1.text = this.event1;
date1.text = this.date1;
location1.text = this.location1;
address1.text = this.address1;
cost1.text = this.cost1;
event2.text = this.event2;
date2.text = this.date2;
location2.text = this.location2;
address2.text = this.address2;
cost2.text = this.cost2;
event3.text = this.event3;
date3.text = this.date3;
location3.text = this.location3;
address3.text = this.address3;
cost3.text = this.cost3;
};
any help would be much appreciated
Externally Loaded Text Prob In Externally Loaded Swf
hi.
so i have a swf that has externally loaded text in it that is being loaded into another swf. the text loads properly when the swf is opened by itself but when the swf is loaded into my main movie the text ceases to appear
my code to load the text is
loadText = new LoadVars();
loadText.load("dates.txt");
loadText.onLoad = function() {
event1.text = this.event1;
date1.text = this.date1;
location1.text = this.location1;
address1.text = this.address1;
cost1.text = this.cost1;
event2.text = this.event2;
date2.text = this.date2;
location2.text = this.location2;
address2.text = this.address2;
cost2.text = this.cost2;
event3.text = this.event3;
date3.text = this.date3;
location3.text = this.location3;
address3.text = this.address3;
cost3.text = this.cost3;
};
any help would be much appreciated
Externally Loading Swf Inside An Externally Loaded Swf
Hey,
So basically, I have a main movie, with buttons for each section (such as home, portfolio and so on). Each button externally loads each section swf into a container. That works fine, all the sections load in and out perfectly.
Now, I want to load some more swfs (like projects in the portfolio section) into the swf thats been loaded from the main movie. Becuase I put my buttons inside movie clips (so that when you roll over the button, the animation finishes if you roll over another half way through), I had to use the tellTarget("/") script to bring it back, but it dosent work, it seems to load the movie into the main movie!
How can I fix this? Iv tried loading it into a different container symbol in the main movie but its still dosent work
Thanks alot.
Externally Loading Swf Inside An Externally Loaded Swf
Hey,
So basically, I have a main movie, with buttons for each section (such as home, portfolio and so on). Each button externally loads each section swf into a container. That works fine, all the sections load in and out perfectly.
Now, I want to load some more swfs (like projects in the portfolio section) into the swf thats been loaded from the main movie. Becuase I put my buttons inside movie clips (so that when you roll over the button, the animation finishes if you roll over another half way through), I had to use the tellTarget("/") script to bring it back, but it dosent work, it seems to load the movie into the main movie!
How can I fix this? Iv tried loading it into a different container symbol in the main movie but its still dosent work
Thanks alot.
Preloader In Externally Loaded Swf Stops Working (loaded Into An Empty Movie Clip)
SEE BOTTOM OF THREAD FOR CURRENT PROBLEM
1. I have my navigation buttons in level0
2. When a button is pressed it loads an external .swf into the highest empty level
3. There is an MC in this loaded .swf called loadmovie and inside that another MC called empty.
4. Inside the 'loadmovie' MC, there is a frame action that loads another external .swf file into the 'empty' MC.
The problem I am having is that the preloader that is on the external .swf that is loaded into the 'empty' MC does not work.
It works fine if you test it on its own. But not when loaded into a Movie Clip.
MY SCRIPT:
iBytesTotal = _root.getBytesTotal();
iBytesLoaded = _root.getBytesLoaded();
iBytes = (iBytesLoaded/iBytesTotal)*100;
percentageNumber = Math.round(iBytes)+"%";
setProperty("progressBar", _xscale, iBytes);
Do I have to refrence it differently? Because of where it is situated?
e.g
iBytesTotal = _level32._root.loadmovie.empty.getBytesTotal();
confesed!
Looping A Loaded An Externally Loaded Mp3
I was trying to loop an externally loaded mp3 and suceeded on my machine, but when I upload the swf and mp3, the function will not work in my browser (IE). I tried a relative path, as well as the absolute URL and neither worked. Here is the code I used to loop the externally loaded mp3:
loopSound = function () {
my_sound.loadSound("whisper.mp3", true);
};
my_sound = new Sound();
my_sound.loadSound("whisper.mp3", true);
my_sound.onSoundComplete = loopSound;
my_sound.setVolume(45);
Any help would be most appreciated, I have wasted a lot of time on this already.
Externally Loaded Swf Does Not Stay Loaded
Hello,
I am loading an externally loaded swf that uses a mask to transition in. When the user clicks a different button I am doing a gotoAndPlay that goes to a mask that "unloads" the content (it doesnt actually unload the info is just outside of the mask area. As soon As I jump to that section the movie is no longer loaded and just shows the container clip that I had created for it. The Container Clip is never changed and is the same throughout the whole process. The only thing that changes is the mask animation.
Any input onto why this would happen would be greatly appreciated.
I have tried both loadClip and loadMovie but no luck on keeping the clip loaded.
EDIT
- I have narrowed it down. When I change the mask movieclip the movie unloads for some reason. Is there a way I can keep it loaded?
Centering Loaded Swf
I am loading my swf's into an empty mc on my main stage. My swf's are made up of pictures jpeg's that are different sizes, therefore my swf are all a little different in size. Is there a way to center the loaded swf in my empty mc when it loads? I want all my swf's containing the pics to be centered in the empty mc.
I am doing it this way because I want to use a preloader for all my swf's that contain jpeg's. I don't think there is a preloader that you can use when dynamically loadeing jpeg's....is there?
Centering My Loaded SWF - Almost There
Hello,
I'm attempting to load and center a SWF file using MovieClipLoader.
Here's the code I have so far:
Code:
createEmptyMovieClip("holder", 10);
var mclListener:Object = new Object();
var mcl:MovieClipLoader = new MovieClipLoader();
mcl.addListener(mclListener);
mclListener.onLoadInit = function(){
holder._x = Stage.width/2;
holder._y = Stage.height/2;
}
mcl.loadClip("load.swf", holder);
stop();
//loaded swf size is 170 x 30
This is really close to what I want. It seems to load the SWF a little to the right and lower than center. I attempted to try and use this code in the onLoadInit function, but it placed the image at 0,0:
Code:
mclListener.onLoadInit = function(){
holder._x = (Stage.width/2)-(holder.width/2);
holder._y = (Stage.height/2)-(holder.height/2);
}
Any help would be greatly appreciated...
-John
Centering Loaded SWF In MC
Hi all-
I am loading a SWF into a movie clip that is on my main timeline. I center the movieclip vertically and attach it to the left side of the window. Since I am loading the external swf into this movieclip, is it possible to load the swf with the registration point of the movieclip being in the center rather than loading the swf's upper left corner into the registration point? It matters because I am dynamically centering it vertically on the page whenever he page resizes, and it does it by the registration point, so my loaded SWF right now is centered by the top, not by the center. I know it may sound confusing, so I uploaded a visual diagram of what I am trying to do.
I'm a bit of a noob, so go easy on me! Thanks for any help. Here's the code to load the swf into the movieclip, called from the timeline of the movieclip:
var imageRequest:URLRequest = new URLRequest("leftside_home.swf");
var imageLoader:Loader = new Loader();
imageLoader.load(imageRequest);
addChild(imageLoader);
Centering Loaded Movies...
i'm pretty new to scripting, so forgive me if this is a question with an answer of general knowledge. when you load .swfs above larger .swfs is there a way to specify where the second movie loads in relation to the first?
~donnie
Centering Loaded Movies...
i'm pretty new to scripting, so forgive me if this is a question with an answer of general knowledge. when you load .swfs above larger .swfs is there a way to specify where the second movie loads in relation to the first?
~donnie
Centering Many Loaded Swfs
I'm loading in swfs into a blank MC but I want the new swf to be centered on
the stage. I've read through the archives and is seems easy if you know the
dimensions of the swf which is to be loaded. Unfortunately I'm gonna be
using different sized MCs although they will be all loaded into the same
holder MC.
Does anyone have any ideas how this can be done?
Thanks
Centering External Loaded .swf
hello all, here's my question???
i have learn to load external swf's but for some reason its on the top left corner. i would to center these swf in the middle can some one help pls.
Centering External Loaded .swf
hello all,
i understand how to load an external .swf, but i don't want it to be in the left hand corner of my movie
i know that i have to create a movie clip to hold the newly loaded movie, but where do i create the the mc and how??
Centering A Dynamically Loaded Jpg
Is it possible to center a jpg which is dynamically loaded into a MC? I am going to be loading images into an empty MC, but the images will be different sizes. Would it be possible to define an area, and have the images centered inside this area?
I hope you understand what I'm talking about....
Thanks
Centering The Loaded Movie
I loaded external movie to level 1
now it is playing upper left hand corner.
How do I place it in the center stage?
Thx in advance.
Centering Dynamically Loaded JPG?
Is it possible to load a jpg into the swf and have it centered in the Movieclip rather than appear from the top left registration point?
cheers
Centering A Loaded Image.
My movie clip loads an external image to the screen. The image is loaded onto a movie clip located in the upper left corner of the screen xy cordinates 0,0.
code:
_root.image.loadMovie("imageName");
Now I want to center the image to the middle of the screen.
code:
_root.image._x = ( 400 - (_root.image.width/2) )
This should center the image horizontally considering that the screen is 800 pixels wide. It does not seem to work for some reason. Could anyone help?
Centering Loaded Movies
When you loadmovie into a target it automaticly places the image at 0,0. But I want the loaded image to be centered. Does anybody know a method of doing this?
Thanks.
I am using Flash MX and the Actionscript I am using in a button is
onbutton (press) {
loadmovie("./load/jepg/image.jpg", "movietarget")
}
Centering Dynamically Loaded .jpg
I'm trying to get the dynamically loaded image to be centered in the MC instead of having the images upper left corner being aligned with the center Reg point of the MC.
Below is the code I'm using.
thanks
james/nyc.
----------------------------------------
slides_xml = new XML();
slides_xml.onLoad = startSlideShow;
slides_xml.load("slides.xml");
slides_xml.ignoreWhite = true;
function startSlideShow(success) {
if (success == true) {
rootNode = slides_xml.firstChild;
totalSlides = rootNode.childNodes.length;
firstSlideNode = rootNode.firstChild;
currentSlideNode = firstSlideNode;
currentIndex = 1;
updateSlide(firstSlideNode);
}
}
function updateSlide(newSlideNode) {
imagePath = newSlideNode.attributes.jpegURL;
slideText = newSlideNode.firstChild.nodeValue;
loadMovie(imagePath, targetClip);
}
next_btn.onRelease = function() {
nextSlideNode = currentSlideNode.nextSibling;
if (nextSlideNode == null) {
break;
} else {
currentIndex++;
updateSlide(nextSlideNode);
currentSlideNode = nextSlideNode;
}
};
back_btn.onRelease = function() {
previousSlideNode = currentSlideNode.previousSibling;
if (previousSlideNode == null) {
break;
} else {
currentIndex--;
currentSlideNode = previousSlideNode;
updateSlide(previousSlideNode);
}
};
-----------------------------------------------
Centering Loaded Movies
I have 2 movieclips right now. One is a background called "canvas" which is used to create a border around the loaded Jpeg, and another called "loader" which the Jpegs load into.
The code for each are as follows:
Canvas code:
onClipEvent (enterFrame) {
if(_parent.loader.getBytesLoaded()>=_parent.loader .getBytesTotal()&&_parent.loader.getBytesLoaded()> 1000){
this._width += (_parent.loader._width-this._width+20)/7;
this._height += (_parent.loader._height-this._height+20)/7;
}
if (math.round(_parent.loader._width+20) == math.round(this._width) && _parent.loader.getBytesLoaded()>1000 ) {
_parent.loader._alpha +=25;
} else {
_parent.loader._alpha = 0;
}
}
Loader code:
onClipEvent(load){
_parent.canvas._x=this._x-10;
_parent.canvas._y=this._y-10;
}
Right now, the canvas scales nicely to the size of the loaded image, while retaining a nice border around it. However, it scales from the top left corner. I want it to scale from the center.
I got the canvas to scale from the center by changing the MC's registration point to the middle. Problem now, is how can I get the loaded JPEGs to position themselves directly center over the canvas?
Thanks.
--iMat
Centering Loaded Objects
I am building a picture gallery
the whole point is to have a defalt gallery that can be used many times for many diffrent sets of images with as little editing as possible
I am using loadMovie command to import the requested image into the scene
EX:
pictureset = the name of the set of images I want loaded
loadMovie("http://www.meta-phor.com/images/"+pictureset+"/test"+_currentframe+".jpg", "imageloader", "GET");
all that is left to do is make sure the image is centered once it is loaded...
because right now I can not figure that out. There will always be two diffrent sizes...
horizontal 720x480
&
vertical 480x720
Can anyone tell me a way to make the images always center themselves to the center if the movie?
here is a version of the swf
http://www.meta-phor.com/tests/testgallery.html
and a still tram of the set up
http://www.meta-phor.com/tests/Picture1.jpg
(i put the registration in the upper left. I'm not sure if that is going to help, hurt, or dosn't matter.)
thanks for any advise you can offer!
Centering A Loaded JPG Image
i'm having a real problem centering a loaded jpg after it's aleady been loaded. i have it loading centrally at a smaller scale using this script:
Code:
//Step1
createEmptyMovieClip("img002", 0);
img002._visible = false;
//Step2
img002.loadMovie("photos/01/03.jpg");
//Step3
this.onEnterFrame = function() {
BLoaded = img002.getBytesLoaded();
BTotal = img002.getBytesTotal();
percent = BLoaded/BTotal*100;
//Step4
if (BLoaded == BTotal && BLoaded>0) {
img002._width = _width/10;
img002._height = _height/10;
img002._visible = true;
delete this.onEnterFrame;
img002._x = 0-_width/2;
img002._y = 0-_height/2;
img002._alpha = 50;
}
};
but i then want it to appear full size, centred to the other images on the page.
i don't want to use specific coordinates to do this as the jpg images will vary in size and will be changed in the future.
i've been trying all day to do this with "photo 3" in my library (see attached file), using this script:
Code:
on (release) {
img002._width = _width*10;
img002._height = _height*10;
// THIS IS WHERE I'M HAVING PROBLEMS:
img002._x = (_root.fullimage._width/2);
img002._y = (_root.fullimage._height/2);
_root.gotoAndStop("f3");
gotoAndStop(4);
}
and i then want it to return to the original position once it is reduced again in scale.
please help!
thanks
Centering Loaded Images
I've been making a modified version of the Dynamic JPG image loader thing that comes with Flash MX I've got it loading captions in from a loaded textfile and then I'm pulling the captions I need from an array.
Basically I'm having a great time until.... I started pulling in pictures of that were both Landscape and Portrait in format. The problem is that they always load in the top Left corner of the clip I'm loading them into. I understand this is because of the "zero" point and the fact that the data loads into positive x and y co-ords. Is there a way to make portrait and landscpe pics load so that their center point are in the same spot regardless of the image size?
Did I explain that correctly....?
Thanks in advance,
Rupert
Centering A Loaded Movie
I'm loading several movies in level 1, all those are different sizes,
so what I'm doing is a button to load the movie and then modifying
the x and y properties. The problem is no matter where Y put the
_level1._x I get the movie loaded at bottom left of my stage, and then
on realease the movie is centered.
If I put this code
_level1._x = (Stage.width / 2) -175
_level1._y = (Stage.height / 2) -235
on press event is the same...
My actual code is:
on (press) {
loadMovie("01.swf" , 1);
}
on (release) {
_level1._x = (Stage.width / 2) -175
_level1._y = (Stage.height / 2) -235
nextFrame();
}
What I need is the movie loaded directly on center...
Centering Loaded JPEG In MC
Hi guys. I've looked all over the forums for an answer to this. Basically I want to know how you can load a JPEG in a MC and keep it centered?
For example: I'm working on a photography site. Some pix are vertical and some horizontal. Each shows up in different positions according to their top left corner.
How can you work around this and have them be centered in a movie or area? I will gladly PayPal anyone $40 for a solution!! (Yes I am that desperate for a solution!)
Thanks for any help!
- Will
Centering Loaded Content
ok here's my problem,
I have an index.swf that it's dimensions are 1020x610, now when I load content in a container in the index.swf it will be centered using an onResize stage listener, that works fine but only if the loaded content is 1020x610, I've also used an onEnterFrame that checks if the width and height are !=0 so that way it waits for it to load before centering the content.
What should I do to always keep my content centered. Lets say I want to load a swf that is smaller (ie the 1st frame only contains 1 element that is smaller than the stage dimensions) I'm not sure if I'm explaining this well....
Centering Loaded JPEG In MC
Hi guys. I've looked all over the forums for an answer to this. Basically I want to know how you can load a JPEG in a MC and keep it centered?
For example: I'm working on a photography site. Some pix are vertical and some horizontal. Each shows up in different positions according to their top left corner.
How can you work around this and have them be centered in a movie or area? I will gladly PayPal anyone $40 for a solution!! (Yes I am that desperate for a solution!)
Thanks for any help!
- Will
Centering A Dynamically Loaded Jpg
pardon me if this has already been dealt with...
i'm working on a small site that i want to dynamically load a jpg into a mc that i have already created (with a mask) and then center the loaded image within this mc.
i have the loading part down, but the loaded image is anchored to the top left. how can i center the loaded image? i'm guessing that i'm going to have to wait until it's loaded, but after that, i'm completely not getting what to do as i'm fairly new to figuring out/creating more complex actionscript.
any help is appreciated.
-ty
Centering A Loaded .swf Without Resizing?
Hello, I would like to have my flash movie full screen, and be able to dynamically load .swf movies in levels above it centered without resizing. How would I go about doing this?? Please Help!!! Thanks Alot!
Centering Loaded Swf's Dynamically
I have a clip that loads a swf based on the variable set by the link clicked. I would like to have the loaded movie centered when it comes in. So my script would be something like
loadedMovie._x=265-(loadedMovie._width/2)
where 265 is the midpoint of the parent clip. This is just the x location, but the y would be similar of course. But for some reason this doesnt work when i upload to the web and try it. It works locally though...
any ideas? or maybe a better way to do this? whats going on??
thanks to anyone who can help!
-Ethan
Pop Up From Externally Loaded Swf
I have the main index .swf and inside that .swf I have another externally loaded .swf. In that swf though I have a link to a 3rd party website that I need to load in a new window. The standard code that i have been using is:
btn_Up.onRelease = function() {
getURL("javascript:Launch('http://www.somewepsite.com, 600,600)");
};
Where btn_Up is the button. But for some reason because the swf is embedded into another swf it doesnt work. Please help!
Externally Loaded FLV
In my SWF fie, I have an externally loaded FLV file.
I now want to add another FLV that will load and play automatically when the first one is finished.
I actually want the SWF to jump to a new scene when the first movie is done.
How can I do that/ what the actionscript?
Steven
Pop Up From Externally Loaded .swf
I have a flash movie, that has a external .swf getting loaded into it, from that .swf I have a button, on that button I would like a script that will have a pop-up without toolbars, and at a certain size. What is the script added to the button for this? Thanks.
Externally Loaded Swf
Hello all,
I just made a flash site with buttons on top and I put a empty movie clip called "container" in the middlle of the site. All animation and buttons will animate and appear and "flash" around until frame 90. The site ends at frame 100. I then included the following code in frame 100:
_root.currMovie = "PEhome";
container.loadMovie(_root.currMovie + ".swf" );
stop();
How come it won't load the external .swf into the container?
Can anyone tell me what am I not doing right and what should be done to fix this problem. Thank you very much.
Ryan
HELP Mii With Externally Loaded SWF
hi there peps i jus need a tiny help with my externally loaded swf file and this so far is the AS am using loadMovieNum("<A href="http://www.geocities.com/krizinxgren/7UP.swf",0">http://www.geocities.com/krizinxgren/7UP.swf",0); please ignore the geocities address OK the code works well well but the situation is that instead of the loaded swf to play/run inside my main movie some how my main movie does not show instead all i can see is the loaded swf only still i learnt that i have to create a container or somthing but i still dono how the container function works please peps any help is a blessing to my work our works everybody
thanks all
K
HELP Mii With Externally Loaded SWF
hi there peps i jus need a tiny help with my externally loaded swf file and this so far is the AS am using loadMovieNum(http://www.geocities.com/krizinxgren/7UP.swf,0); please ignore the geocities address, the code works well well but the situation is that instead of the loaded swf to play/run inside my main movie some how my main movie does not show instead all i can see is the loaded swf only still i learnt that i have to create a container or somthing but i still dono how the container function works please peps any help is a blessing to my work our works everybody
thanks all
K
Pop Up From Externally Loaded .swf
I have a flash movie, that has a external .swf getting loaded into it, from that .swf I have a button, on that button I would like a script that will have a pop-up without toolbars, and at a certain size. What is the script added to the button for this? Thanks.
Externally Loaded Swf
Hello all,
I just made a flash site with buttons on top and I put a empty movie clip called "container" in the middlle of the site. All animation and buttons will animate and appear and "flash" around until frame 90. The site ends at frame 100. I then included the following code in frame 100:
_root.currMovie = "PEhome";
container.loadMovie(_root.currMovie + ".swf" );
stop();
How come it won't load the external .swf into the container?
Can anyone tell me what am I not doing right and what should be done to fix this problem. Thank you very much.
Ryan
Externally Loaded Swf
This is probably covered somewhere, but I am loading an external .swf into my main movie and i am just wondering if the actionscript works in the external swf. I see what i am assuming are pages with an external load and most have a preloader. How does this work.
Using PHP In An Externally Loaded SWF
:?
I've constructed a site in Flash, using an external loader. The tutorials on this site are great, thanks. I've made a contact page that uses php script, which has full functionality when previewed OR viewed as an independent HTMP page. However, when I submit contact info from the live site, I never receive any email. Can anyone tell me why this is??
I've tried everything I can think of, and have allowed every file in site folder access through the Flash Player Control Panel. I followed Lee's tutorials for both external loaders and the php contact page extactly.
Thanks in advance for any help!
http://www.simplypilatesnashville.com
Centering Loaded External Jpegs
I've seen similar questions to this here, but I couldn't find any clear answers. I am loading external jpegs into my site and I want to get their size (width, height) so I can position them appropriately once they're loaded. How do I get their size and re-position them? I've been trying to use getProperty, but I can't seem to get that to work. Any help would be greatly appreciated - I'm stumped. This is basically how I am loading the jpegs.
Code:
_root.holderMC.loadMovie("products/image.jpg);
Centering Loaded Jpegs Automatically
I have written this little piece of code that works great. It centres and resizes jpegs loaded into a holder_mc. Problem is that the OnClipEvent.data command that triggers it needs to actually be on the holder_mc or it doesn't retrieve the size of the incoming jpegs poperly. Does anybody know of a better way to do this??????I know there must be a better way! with remote code that doesn't need to be attached to the holder_mc. Any help would be appreciated. If your looking for something like this...please take this code and check it out...it works quite well and saves tons of time if you like loading in jpegs for galleries. here's my code
function centreAndSize() {
size=400 //the maximum height or width you want your image to be sized to
//this code scales the image
width=(_root.imageHolder._width)//the width if the loaded image before it is sized
height=(_root.imageHolder._height)//the height of the loaded image before it is sized
ratio=width/height//a ratio to determine the
if (width>height){
_root.imageHolder._width =size;
_root.imageHolder._height =size/ratio
}else{_root.imageHolder._height =size;
_root.imageHolder._width =size*ratio
}
// this code centres the image after loaded
stageWidth=760//could use the Stage.width property directly but the html window doesnt cetnre properly if resized by user
stageHeight=500//Stage.height
_root.imageHolder._x = (stageWidth / 2) - (_root.imageHolder._width / 2) ;
_root.imageHolder._y = (stageHeight / 2) - (_root.imageHolder._height / 2) ;
}
Centering An Image Loaded As A Movie
Hi there
I've built a slide show for a gallery. The images are brought in to an empty sldeshow movie placed on the main timeline. Naturally the images are all aligned to the slidesow movie clip at the topleft. As i have both portrait and landscape pictures of varying sizes. how can i bring the image in using the centre of the imge as the location reference. All starts getting a bit too maths on me.
Any offer a solution
thanks in advance
ash
[CS3] Centering Loaded Movie And Buttons
Hi,
I'm working on a site which has a stage listener to dynamically reposition the elements depending on the size of the stage.
Im loading a movie into this and want it to dynamically position also.
I have achieved this by loading it into an empty movie (instance name dropzone) on the stage,
on (release) {
_root.dropzone.loadMovie("collection.swf",1);
however the buttons in the collection.swf no longer find their targets, due to being loaded into the new movie. I was using absolute references within the collection.swf movie, and also tried relative references, but still no luck.
I have also tried loading into a new level with loadMovieNum
loadMovieNum("collection.swf", 1);
var xset = 200;
var yset = 200;
(where xset and yset are within collection.swf to control _X and _y)
and this allows me to assign the button references inside collection.swf to within _level1
tellTarget ("_level1.image") {
gotoAndStop(2); }
this works for the buttons, but the position of collection.swf is set, and not repositioned dynamically
Is there a correct way to assign actions to the buttons within the collections.swf file so that they are still recognised when loaded in the dropzone movie?
Thanks for your help.
Andy
|