<html><div style='background-color:'><P>I've just got back from town, might be a little bit drunk, but this thread is gettin on my nerves, -timers?</P>
<P>timers are unreliable and they double suck the processing power of your allready heavy multidimensional array.</P>
<P>Timers should be considered only as the last resort, but somebody jumped to it as first.</P>
<P>You've never explained on how you're invoking these: show, slow, hide functions at all. That might've been very helpfull for people trying to help.</P>
<P>I wouldd sugest the first thing that comes to my mind, -classical aproach. </P>
<P>(if you haven't tried this already!)</P>
<P>instead of calling the sllow function, -call the "show" function, 9why not even use conditionals: loadinggif.style.visibility='visible';(than posibly?!) if (loadinggif.style ... =='visible'){/and only then call:/ slow...()} , afterwards, in the 'slow' function after slow instructions ended, include the: hide() function call. /but this might also trigger earlier than the slow function has finished, than, if it does, why not use some var true /false and the condition if true that is, -the slow function has completed! than hide the damn loadinggif. This should kick in all browsers and machinery used worlwide. Dont know why, but Timers always left me down!...<BR><EM> *even the scripts obey the cascading logic, -if you have functions defined show();slow(); hide(); and called outside of some other function: it is absolutely clear that the show() /hide()
functions will execute instantly,(while the slow one will take its time) same as with CSS, if you declared hidden eleenmnt in CSS but you've declared the same element again as visible below or inline - it will surely override your first declaration long beforre it has ever been displayed.<BR></EM>It has hapened something very similar to this case with your script, -try the above might proove fruitfull.</P>
<P><FONT style="FONT-SIZE: 11px; FONT-FAMILY: tahoma,sans-serif">Troy III <IMG height=19 src="http://graphics.hotmail.com/i.p.embeer.gif" width=19> cheers!</FONT></P>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #a0c6e5 2px solid; MARGIN-RIGHT: 0px"><FONT style="FONT-SIZE: 11px; FONT-FAMILY: tahoma,sans-serif">
<P>
<HR color=#a0c6e5 SIZE=1>
</P>
<P>From: <I>"SkyScanner" <skyscanner@eircom.net></I><BR>Reply-To: <I>"\[JavaScript List\]" <javascript@LaTech.edu></I><BR>To: <I>"[JavaScript List]" <javascript@LaTech.edu></I><BR>Subject: <I>Re: [Javascript] Order of script-processing</I><BR>Date: <I>Mon, 26 Sep 2005 19:16:57 +0100</I><BR><BR></P>
<META content="Microsoft SafeHTML" name=Generator>
<STYLE>
</STYLE>
<DIV><FONT face=Arial size=2>The setTimeout argument is actually in milliseconds, not seconds. It works in the right order only if I use 2 timers - one of the querks of JS! The image-hide runs after the slow routine, no matter how long it takes. </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Tim in Ireland</FONT></DIV>
<BLOCKQUOTE style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> <A title=glenn_lanier@netzero.net href="mailto:glenn_lanier@netzero.net">Glenn E. Lanier, II</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=javascript@LaTech.edu href="mailto:javascript@LaTech.edu">'[JavaScript List]'</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Monday, September 26, 2005 2:51 PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> RE: [Javascript] Order of script-processing</DIV>
<DIV><BR></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>I read your flow as three separate routines:</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>show()</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>SetTimer(slow(),5); // Start in 5 seconds.</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>SetTimer(hide(),10); // Start in 10 seconds.</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>What I am suggesting is only one timer:</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>show()</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>SetTimer(slow(), 5);</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>slow()</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>{</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>.....</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>hide();</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>}</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>That way, if slow takes 30 seconds, then the image isn't hidden early.</FONT></SPAN></DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080></FONT></SPAN> </DIV>
<DIV><SPAN class=593054913-26092005><FONT face=Tahoma color=#000080>--G</FONT></SPAN></DIV>
<BLOCKQUOTE dir=ltr style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000080 2px solid; MARGIN-RIGHT: 0px">
<DIV></DIV>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left><FONT face=Tahoma size=2>-----Original Message-----<BR><B>From:</B> javascript-bounces@LaTech.edu [mailto:javascript-bounces@LaTech.edu] <B>On Behalf Of </B>SkyScanner<BR><B>Sent:</B> Monday, September 26, 2005 8:44 AM<BR><B>To:</B> [JavaScript List]<BR><B>Subject:</B> Re: [Javascript] Order of script-processing<BR><BR></FONT></DIV>
<DIV><FONT face=Arial><STRONG>Huh? That's exactly what I did do... show:slow:hide</STRONG></FONT></DIV>
<DIV><STRONG><FONT face=Arial></FONT></STRONG> </DIV>
<DIV><STRONG><FONT face=Arial>Tim in Ireland.</FONT></STRONG></DIV>
<BLOCKQUOTE style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> <A title=glenn_lanier@netzero.net href="mailto:glenn_lanier@netzero.net">Glenn E. Lanier, II</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=javascript@LaTech.edu href="mailto:javascript@LaTech.edu">'[JavaScript List]'</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Monday, September 26, 2005 1:52 PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> RE: [Javascript] Order of script-processing</DIV>
<DIV><FONT face=Arial>showGif('icon_5');<BR>setTimeout("slowRoutine()",10);<BR>setTimeout("hideGif('icon_5')",10);</FONT></DIV>
<BLOCKQUOTE dir=ltr style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000080 2px solid; MARGIN-RIGHT: 0px">
<BLOCKQUOTE dir=ltr style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000080 2px solid; MARGIN-RIGHT: 0px">
<DIV> <SPAN class=564065012-26092005><FONT face=Tahoma color=#000080>[GEL>] Why don't you move hideGif() to the end of slowRoutine? That way, if it takes more time on a slower machine, your image isn't hidden early. </FONT></SPAN></DIV></BLOCKQUOTE></BLOCKQUOTE>
<P>
<HR>
<P></P>_______________________________________________<BR>Javascript mailing list<BR>Javascript@LaTech.edu<BR>https://lists.LaTech.edu/mailman/listinfo/javascript<BR></BLOCKQUOTE></BLOCKQUOTE>
<P>
<HR>
<P></P>_______________________________________________<BR>Javascript mailing list<BR>Javascript@LaTech.edu<BR>https://lists.LaTech.edu/mailman/listinfo/javascript<BR></BLOCKQUOTE><BR>
<P>>_______________________________________________<BR>>Javascript mailing list<BR>>Javascript@LaTech.edu<BR>>https://lists.LaTech.edu/mailman/listinfo/javascript<BR>
<P></FONT></P></BLOCKQUOTE></div><br clear=all><hr>Express yourself instantly with MSN Messenger! <a href="http://g.msn.com/8HMAEN/2728??PS=47575" target="_top">MSN Messenger</a> Download today it's FREE!</html>