Michael a écrit :
> var ajaxSupport = (Ajax.getTransport()) ? true : false;

a.k.a. "var ajaxSupport = !!Ajax.getTransport();

> if (ajaxSupport = true) {

Ahem.  With a single = sign, you'll reassign ajaxSupport, and therefore
ensure it's true.  Beware!  This is why I always put rvalues on the left

        if (3 == myVar)

Also, this code is redundant.  It could as well be:

        if (ajaxSupport)

>         new Element.update('searchengines', '');
>         window.setTimeout('Ajax.Update(\'human_page\')', 500);

What is this Ajax.Update thing?

Christophe Porteneuve aka TDD

You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" group.
To post to this group, send email to rubyonrails-spinoffs@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 

Reply via email to