Salut tout le monde.
Tout d'abord, merci pour ce grand forum et la communauté. Je l'ai trouvé en cherchant une solution à mon problème. (Malheureusement, n'a pas trouvé la solution

).
Ok ça y est, j'ai reçu un preloader Javascript pour les images, fonctionne parfaitement. La voici:
<script type="text/javascript"> // JavaScript Document
var time = 3;
var maxtime = 120;
var done = 1;
time = time * 1000;
maxtime = maxtime * 1000;
loaded = new Array();
function Pre_load()
{
for( index = 0; index < document.images.length; index++ )
{
loaded[ index ] = false;
}
}
window.setTimeout( "document.getElementById('Loading_Img').style.visibility='hidden';", maxtime );
function Preload_Img()
{
imgs = document.images;
for( index = 0; index < imgs.length; index++ )
{
if( done >= imgs.length )
{
break;
}
else if( imgs[ index ].complete && loaded[ index ] == false )
{
done++;
loaded[ index ] = true;
}
}
if( done >= imgs.length )
{
window.setTimeout( "document.getElementById('Loading_Img').style.visibility='hidden';", time );
}
else
{
window.setTimeout( "Preload_Img()", '58' );
}
if( done == imgs.length )
{
window.setTimeout( "window.location.href='intro.html';", time);
}
PRC = Math.round( ( ( done / imgs.length ) * 100 ) );
barwidth = PRC * 2.13 ;
preview =
'<img src="images/loadingbar.gif" width=' + barwidth + ' height = 13/>'
+'<br />'+'<br />'
+ ' '+ PRC + ' ' + '%'
document.getElementById('Loading_Img').innerHTML = preview;
}
Pre_load();
Preload_Img();
</script>
- <script type="text/javascript"> // JavaScript Document
- var time = 3;
-
- var maxtime = 120;
-
-
- var done = 1;
- time = time * 1000;
- maxtime = maxtime * 1000;
- loaded = new Array();
-
- function Pre_load()
- {
- for( index = 0; index < document.images.length; index++ )
- {
- loaded[ index ] = false;
- }
- }
-
-
- window.setTimeout( "document.getElementById('Loading_Img').style.visibility='hidden';", maxtime );
-
- function Preload_Img()
- {
- imgs = document.images;
-
- for( index = 0; index < imgs.length; index++ )
- {
- if( done >= imgs.length )
- {
- break;
- }
- else if( imgs[ index ].complete && loaded[ index ] == false )
- {
- done++;
- loaded[ index ] = true;
- }
- }
-
- if( done >= imgs.length )
- {
- window.setTimeout( "document.getElementById('Loading_Img').style.visibility='hidden';", time );
- }
- else
- {
- window.setTimeout( "Preload_Img()", '58' );
- }
-
- if( done == imgs.length )
- {
- window.setTimeout( "window.location.href='intro.html';", time);
- }
-
- PRC = Math.round( ( ( done / imgs.length ) * 100 ) );
-
- barwidth = PRC * 2.13 ;
-
- preview =
-
- '<img src="images/loadingbar.gif" width=' + barwidth + ' height = 13/>'
- +'<br />'+'<br />'
- + ' '+ PRC + ' ' + '%'
-
- document.getElementById('Loading_Img').innerHTML = preview;
- }
-
- Pre_load();
- Preload_Img();
- </script>
Le probleme est que j'ai eu un ÉNORME swf à charger, et je ne peux vraiment pas savoir comment se comporte la possibilité de le charger de mon preloader image...Toute idée comment procéder?

Merci beaucoup
