title: jquery not working in rails
body: <p>I've read many pages about using jquery in rails and still can't seem to get it to work.</p>
  
  <p>I have the 'jquery-rails' gem, and I installed.
  I have the require statements in the application.js file.</p>
  
  <p>Here is a test page I keep running:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
   &lt;html&gt;
   &lt;head&gt;
  &lt;title&gt;&lt;%= yield(:title)%&gt;&lt;/title&gt;
  &lt;%= javascript_include_tag 'application','jquery', 'data-turbolinks-track' =&gt; true  %&gt;
  &lt;%= stylesheet_link_tag    'application', media: 'all', 'data-turbolinks-track' =&gt; true %&gt;
  &lt;%= csrf_meta_tags %&gt;
  &lt;script&gt;$(document).ready(function(){
    $(".bg-info").click(function(){
      $(this).hide();
  });
   });&lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;center&gt;
  &lt;h1 class="bg-info"&gt;&lt;%= yield(:title)%&gt;&lt;/h1&gt;
  &lt;/center&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>But when I click on the "bg-info" text in the browser I get no response.</p>