Orange is my favorite color

In my application, we have a session with a 60 minute timeout. Organizers sometimes execute long running tasks or they leave their computer in the middle of something and return only to find out on the next submit (sometimes after accomplishing much work) that they are prompted for a username and password again. This causes quite a bit of frustration.

To combat this, we placed a session timeout counter next to the “Logout” link counting down from 60 minutes and alerting the user at both 10 and 5 minutes that they should save their work if necessary. This was nice, but still placed the onus on the user.

Thanks to, we now have an automatic (via setInterval()) process that pings the server every 50 minutes to keep the session alive as long as the browser is open. It was working great in Firefox but for some reason didn’t seem to be firing in IE.

By setting the interval to 2000ms and adding in some dojo.debug()s, I could see that Dojo was calling the server every 2 seconds but that the server was returning the same value in IE. Caching! Should have known. By adding the preventCache argument to my bind() call, no more problems with seemingly not working in IE:

<script language="javascript" type="text/javascript">


In this case, I don’t have an error or load function for handling results from the call. I don’t want to do anything with the results; merely requesting the ColdFusion page will refresh the session timeout on the server side so I use the catch-all “handler” routine to silently ignore everything that comes back.


  1. Yoz Grahame's Cheerleader said:

    on August 13, 2006 at 6:48 pm


    (Warning: Happy tale that rapidly turns into a demented language-war rant.) Based on recent experience doing more extended web dev work than I have for a while, I propose the acronym TPTOTA (pronounced tip-toe-ta), which stands for They’ve Probably Th…

  2. Scott Wilson said:

    on September 11, 2006 at 2:48 am

    Thank you!!! I was just about to file a bug report with the dojo guys that io.bind didn’t work with IE when I stumbled across your page. Good work!

  3. Ralf van Hoof said:

    on January 19, 2007 at 2:51 am

    Thanks for the great tip. It works perfectly! We were getting worried out code might just not work in IE, which is kind of a show stopper if IE is the company standard.

{ RSS feed for comments on this post}