# setInterval, Firefox vs IE

**URL:** <https://forum.kirupa.com/t/setinterval-firefox-vs-ie/188564>\
**Category:** flash\
**Created:** [May 9, 2006, 1:58am UTC](https://forum.kirupa.com/t/setinterval-firefox-vs-ie/188564 "2006-05-09T01:58:11Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mrakuma](https://avatars.discourse-cdn.com/v4/letter/m/c4cdca/32.png) [@mrakuma](https://forum.kirupa.com/u/mrakuma)\
**Post date:** [May 9, 2006, 1:58am UTC](https://forum.kirupa.com/t/setinterval-firefox-vs-ie/188564/1 "2006-05-09T01:58:11Z")

</div>

Hi, I am learning flash and trying to make my own photo gallery. I thought that I had everything working, but that was because I was testing my script with Firefox…

The problem:  
I use a setInterval to show the progress bar when I load a photograph. In Firefox, the % grows until it reaches 100%, and then the loader dissapears. In IE, my loader allways shows 0%, even after the photo loaded… I searched in google and in the forums, but I cant find any similar problem. Can you help me out?

This is my code:

When I change the contentPath of my loader, I run this:  
loadPhotoInterval = setInterval(photograph.loadPhoto, 100);

Inside photograph movieclip I have this code:

function loadPhoto() {  
if (photo.getBytesTotal() != 0) {  
photoloader\_mc.\_visible = true;  
photo\_percent = Math.round(photo.getBytesLoaded() / photo.getBytesTotal() \* 100);  
photoloader\_mc.percent = photo\_percent + “% cargado”;  
if (photo\_percent == 100) {  
photoloader\_mc.\_visible = false;  
clearInterval(loadPhotoInterval);  
} else {  
photoloader\_mc.\_visible = true;  
}  
}  
}

You can see it in action here:  
[http://www.pmarin.com.ar/fotos/galeria.html?id=300&seccion=galerias](http://www.pmarin.com.ar/fotos/galeria.html?id=300&seccion=galerias)
