title: How to include my Javascript file and/or jQuery in my HTML web page
body: <p>I have:</p>
  
  <ol>
  <li><p><code>controller/reports_controller.rb</code></p></li>
  <li><p><code>views/reports/index.html.erb</code></p></li>
  <li><p><code>assets/reports.js</code></p></li>
  </ol>
  
  <p>I have an image in <code>index.html.erb</code>:</p>
  
  <pre><code>&lt;div class="main_mark"&gt;
     &lt;img src="/assets/welcome_main.png" alt="main" class="main_mark_image" /&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I want to print an message to the screen (alert message) when the user presses the image. so I want to write a function in <code>reports.js</code> that print the message.</p>
  
  <p><code>reports.js</code>:</p>
  
  <pre><code>$(document).ready(function() {
      $(".main_mark_image").click(function () {
          alert("alon");
      });
  });
  </code></pre>
  
  <p>but I think I have to relate between the java script the the html.</p>
  
  <p>any help appreciated!</p>