A little bit shorter, and does the same:

var _supportsAjax = !!Ajax.getTransport();

I think there's no better way to acomplish this.

hth

sigi

On 9/13/06, Ed C. <[EMAIL PROTECTED]> wrote:
Hello,
 
Does anyone have an elegant way to check if the client supports AJAX? I'm currently using:
 
     var _supportsAjax = (Ajax.getTransport()) ? true : false;
 
Thanks,
Ed C.





--
Siegfried Puchbauer
--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs
-~----------~----~----~----~------~----~------~--~---

Reply via email to