Why not just use Ajax.Updater's onCreate callback to set an in_process
flag to true, and onComplete to false, and just put your ajax call
inside an if (!in_process) { Ajax.Updater ... }

-patrick

On Oct 27, 6:09 pm, JoJo <tokyot...@gmail.com> wrote:
> I wanted to prevent rapid double clicking of an AJAXed tab.  My code
> works well in IE8, FF, and S.  In IE7 and 6, the tab gets disabled
> permanently even though I see both window.status calls printing out
> the expected stuff.  What's going on?
>
> ++++++++++++++++++++++++++
>
> var tabOnclick = tabElement.down('a').readAttribute('onclick');
> window.status = tabOnclick;
> tabElement.down('a').writeAttribute('onclick', null);
>
> new Ajax.Updater(
>    'tabContentArea',
>    'someServerScript.php', {
>       onComplete: function() {
>          new PeriodicalExecuter(
>             function(myself) {
>                tabElement.down('a').writeAttribute('onclick',
> tabOnclick);
>                window.status = 're-enabled : ' + tabOnclick;
>                myself.stop();
>             }.bind(this),
>             2
>          );
>       }
>    }
> );
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to