-
preloading problem
hi everyone!!
to make a long story short, i made a site with some flash animation.
the problem is they are slightly long to load, so i thought "hey why not put a preloading thingy"
i looked through almost every website possible and i came up with a preloading that please me.
The thing is...it wont preload =,=
here is the link to the site http://cervera.stephanie.free.fr/resolution%20petite/
the animation is right at the entrance, but for some reason, while it's loading, i only got a blank square, then everything load at the same time.
[url]http://cervera.stephanie.free.fr/Image1.jpg[url]-> here is what i get
could someone help me pretty please (im very desperate)???
oh and here is the action script im using:
onClipEvent (load) {
total = _root.getBytesTotal();
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded();
percent = int(loaded/total*100);
perc1 = ""+percent+"%";
gotoAndStop(percent);
if (loaded == total) {
_root.gotoAndPlay(2);
}
}
and here, the html link
<object type="application/x-shockwave-flash" data="entree.swf" width="650" height="450">
<param name="play" value="true" />
<param name="movie" value="entree.swf" />
<param name="menu" value="false" />
<param name="loop" value="false"/>
<param name="quality" value="high" />
<param name="scalemode" value="noborder" />
<p>Vous n'avez pas Flash Player ou votre navigateur bloque un script/activeX,
<br>veillez à autoriser le contenu bloqué de la page ou à télécharger Flash Player, merci</p>
</object>
maybe ive done something wrong, but i have no clue what
ToT
thanks ^-^
-
It would be easier to diagnose the problem if you attached your source file. The issue is probably where you're adding the actionscript.
A couple things to check:
1) Are there any Flash components in your movie?
2) Is there something on Frame 1 or 2 of your movie?
If you can't attach the source, go to gotoandlearn.com and view the tutorials on preloading. There are also sample files available that will help to guide you. If that doesn't fit the bill, Blizzard has a nice tutorial on preloading in the Tips & Tutorials forum here at DD.
HTH
-
thanks u!!
i'll go check all those site right away =3
oh and the source is there: http://cervera.stephanie.free.fr/res...ite/entree.fla
-
ok now its weird coz i've re-done my preloader (like its shown on gotoandlearn.com)and when i simulated it, it worked but on ie it doesnt show, and on firefox it does....where am i wrong???
im completly clueless.
-
Hmm, not sure.
Can you post the source of your re-done preloader and I'll take a look. ActionScript isn't browser dependant, so that shouldn't be happening.
It might be due to how you're embedding the flash.
-
this is so weird XD
the link to the flash source is still the same
http://cervera.stephanie.free.fr/res...ite/entree.fla
and here the swf link
http://cervera.stephanie.free.fr/res...ite/entree.swf
and here the html link
http://cervera.stephanie.free.fr/res...ite/index.html
I really hope u can find something, cause at this point...i almost want to give up and screw this damn preloader >.>
xD
-
Maybe try this one:
Code:
<body onload="document.getElementById('loading').style.display = 'none';document.getElementById('content').style.display = 'inline';">
<div id="loading" style="padding-top:50px;">
<!-- what you wish to appear -->
</div>
<div id='content' style='display:none;'>
<!-- content of your site -->
</div>
-
Quote:
Originally Posted by
chechu
Maybe try this one:
Code:
<body onload="document.getElementById('loading').style.display = 'none';document.getElementById('content').style.display = 'inline';">
<div id="loading" style="padding-top:50px;">
<!-- what you wish to appear -->
</div>
<div id='content' style='display:none;'>
<!-- content of your site -->
</div>
I'm not sure if that would work or not. I guess trying it is the only way to find out. The issue here is preloading within Flash.
Anyway, your issue is definetely your embedding technique. For starters you have paragraph (<p>) tag within your embed tag. I'm not sure what you're trying to do there.
You're eventually going to run into the "Click to activate" bug in Opera and IE. So, you can kill two birds with one stone and use SWFObject 2.0 to embed the code and that should take care of all of your troubles.
-
oh my god, medyman, you're my savior ^o^
it does seem to work!
i'll upload on my ftp and test everything on every browser available!!
really thanks! i dont know what i'd have done if you weren't there T0T
(note: if it doesnt work i'll post again >.>)
oh and chechu thanks =3
EDIT: it's working allright!! thanks a lot ^-^
-
You're welcome :D
Glad it worked for you.
-
ok im back with another problem *fall on knees*
everything work perfectly fine...except...ya except...my flash animation is on loop reading and...Well...the preloader keep showing when the animation start over *cry* (note: i'd like the animation to be on loop)
is there a way so it doesnt show or something????
*bow*
-
You can't have the entire thing loop. You'll have to place whatever is after frame 2 into its own movieclip.
Just highlight all of the frames after frame 2. Right click and choose copy frames. Then hit Ctrl + F8 to create a new symbol. Go to the new blank timeline, right click and choose paste frames.
Then place this new movieclip on frame 3 on the main timeline. Make sure you delete all the other frames that you had.
Lastly place a stop(); action on frame 3.
HTH
-
oh my god im such a noob xD
thanks god you were there =3
everything work just fine
thanks again so much (you...saved my life!!)
*toddle off*