dcsimg
A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: loadMovie and Mozilla/Firefox

  1. #1
    Junior Member
    Join Date
    Nov 2003
    Posts
    11

    loadMovie and Mozilla/Firefox

    Having an issue with a really basic swf. I've got empty movie clips already created on the stage that loads jpg's into those clips using loadMovie. It displays and works perfectly in IE and standalone but will not display the loaded images in Mozilla/Firefox.

    Anyone have an idea of why this is?

  2. #2
    Senior Member
    Join Date
    Sep 2000
    Location
    Pittsburgh
    Posts
    252
    Hi Bryan,

    I've never seen this problem. Is this mac or pc? Are there spaces in the file names of the images? Do you have an example for us to try online so we can replicate it and rule out the fact that it might be machine specific?

    Dunc

  3. #3
    Junior Member
    Join Date
    Nov 2003
    Posts
    11
    Here's the swf:

    http://www.fourthtime.com/launcher_basic_dynamic.swf

    And the relevant code:

    Code:
    function propagate() {
    this.launcher_mc.alliesBackground_mc.loadMovie("http://www.fourthtime.com/allies1.jpg");
    this.launcher_mc.alliesOver_mc.loadMovie("http://www.fourthtime.com/allies2.jpg");
    this.launcher_mc.axisBackground_mc.loadMovie("http://www.fourthtime.com/axis1.jpg");
    this.launcher_mc.axisOver_mc.loadMovie("http://www.fourthtime.com/axis2.jpg");
    }
    
    this.onLoad = function() {
    propagate();
    link();
    };
    Construction is very simple. All movie clips are already empty and sitting on the stage in the correct positions. On the stage is the launcher_mc which holds the other clips which are layered to have background on the lowest, rollover image in the middle and the hit clips on top.

    In IE everything shows up fine even when grabbing the images cross-domain but Mozilla/Firefox will not. I did have one colleague confirm this thus far. In Mozilla/Firefox you can see it is running because the hit clips are right there when you roll your mouse around but the images won't load.

    Thanks for any help.

  4. #4
    Senior Member
    Join Date
    Sep 2000
    Location
    Pittsburgh
    Posts
    252
    looks like it's a problem with the onload handler. to be honest i don't know why it would work in IE and not firefox. but if you dump this.onLoad and just call the propagate function it will work in firefox. did a quick search and couldn't find any technotes or info on it but i've also never used the onload event for a movie or mc. not much of an answer but it should get you over the hump.

    good luck,
    Dunc

  5. #5
    Junior Member
    Join Date
    Nov 2003
    Posts
    11
    Will give it a shot tomorrow and let you know how it works.

    Thanks Dunc

  6. #6
    Registered User
    Join Date
    Feb 2001
    Posts
    13,044
    Hi,

    I get the impression that this.onLoad does not exist - or if it does, that the loading targets do not exist.
    The movie does not even attempt to sk the server for images

    Musicman

  7. #7
    Junior Member
    Join Date
    Nov 2003
    Posts
    11
    Dunc it works. I ended up just calling the function one time by placing a call for it before the stop();


    Musicman... it was a stupid way to call a function and nothing more lol. Of course this.onLoad isn't going to do anything because 'this' is the root so it's already loaded before the script can even check. Why it was working in IE for a bit I have no idea but it was bad programming regardless lol.

    Thanks guys. This will definetly help me. Been about 6 months since I've done any scripting so I'm a bit rusty. Thanks again.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center