# jQuery Users

**URL:** <https://www.ruby-forum.com/t/jquery-users/89367>\
**Category:** Rails\
**Created:** [March 19, 2007, 11:17pm UTC](https://www.ruby-forum.com/t/jquery-users/89367 "2007-03-19T23:17:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sshefer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d9b06d/32.png) [@sshefer](https://www.ruby-forum.com/u/sshefer)\
**Post date:** [March 19, 2007, 11:17pm UTC](https://www.ruby-forum.com/t/jquery-users/89367/1 "2007-03-19T23:17:08Z")

</div>

Any jQuery users out there? I would like to learn more about  
incorporating jQuery with Rails as the performance seems to be the  
best of any library I’ve seen and it is great in separating the  
JScript from the HTML. Any suggestions on where to get started? I’ve  
read this ([http://b.lesseverything.com/2006/12/31/making-jquery-and-](http://b.lesseverything.com/2006/12/31/making-jquery-and-)  
prototype-play-nice-in-rails) but was looking into some more.

Also UJS looks interesting and has greater support - are more people  
using this?

---

<div class="post-metadata">

**Author:** ![sshefer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d9b06d/32.png) [@sshefer](https://www.ruby-forum.com/u/sshefer)\
**Post date:** [March 20, 2007, 2:26pm UTC](https://www.ruby-forum.com/t/jquery-users/89367/2 "2007-03-20T14:26:42Z")

</div>

Just wanted to mention that by saying UJS has greater support I mean  
in Rails. jQuery has many more resources and valuable results with a  
simple Google search.

---

<div class="post-metadata">

**Author:** ![sshefer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d9b06d/32.png) [@sshefer](https://www.ruby-forum.com/u/sshefer)\
**Post date:** [May 9, 2007, 6:13pm UTC](https://www.ruby-forum.com/t/jquery-users/89367/3 "2007-05-09T18:13:55Z")

</div>

Shai,

I prefer jQuery to Prototype in rails apps, but it is getting to be a  
burden  
to integrate some things. Some of my latest code seems hacky, but I  
really  
dislike “onclick” event bindings!

I posted a similar question a few months back (I think there was talk of  
a  
jQrails or something similar) but I haven’t found anything so far.

---

<div class="post-metadata">

**Author:** ![sshefer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d9b06d/32.png) [@sshefer](https://www.ruby-forum.com/u/sshefer)\
**Post date:** [May 9, 2007, 9:42pm UTC](https://www.ruby-forum.com/t/jquery-users/89367/4 "2007-05-09T21:42:44Z")

</div>

I’m currently using both Prototype and JQuery in the same Rails app.  
Not  
really something I’d recommend, but my designer (my wife) wrote a bunch  
of  
the webapp using JQuery before I ever touched it with Rails (including  
Thickbox functionality), so in the interest of time, I kept her code  
(heh -  
she also insisted that I keep it) and later on in the process I found  
that I  
wanted to use some Prototype stuff as well.

I found this article to be helpful:

[http://docs.jquery.com/Using\_jQuery\_with\_Other\_Libraries](http://docs.jquery.com/Using_jQuery_with_Other_Libraries)

In each file and/or block using jquery code, I used a line like

var $j = jQuery.noConflict();

And then I replaced each $ with $j. It was tedious, and I had to modify  
the  
thickbox.js as well, but it all works together now.

Again, I don’t recommend using jquery and prototype at the same time  
unless  
your wife decides that you will. 🙂

On 5/9/07, John L. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> On 3/20/07, Shai S. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > Just wanted to mention that by saying UJS has greater support I mean  
> > in Rails. jQuery has many more resources and valuable results with a  
> > simple Google search.
> > 
> > > >

–  
Terry (TAD) Donaghe  
[http://tadspot.tumblr.com](http://tadspot.tumblr.com)
