title: Rails 3.0 to 3.1 Javascript error
body: <p>I am trying to learn to use Javascript in Rails and am following a Tutorial at <a href="http://net.tutsplus.com/tutorials/javascript-ajax/using-unobtrusive-javascript-and-ajax-with-rails-3/" rel="nofollow">http://net.tutsplus.com/tutorials/javascript-ajax/using-unobtrusive-javascript-and-ajax-with-rails-3/</a></p>
  
  <p>Even though the tutorial is written for 3.0, since Rails 3.1 is out I am using it  and running into an error.  Following the lesson to the "AJAX form submission" part where it builds a js.erb file with the following content;</p>
  
  <pre><code>    $('body').html("&lt;h1&gt;&lt;%= escape_javaScript(@post.title) %&gt;&lt;/h1&gt;").append("&lt;%=         escape_javaScript(@post.content) %&gt;");
  </code></pre>
  
  <p>I am getting the following error in the server log;</p>
  
  <pre><code> ActionView::Template::Error (undefined method `escape_javaScript' for #&lt;#&lt;Class:0x00000100917048&gt;:0x0000010084b0d8&gt;):
  1: $('body').html("&lt;h1&gt;&lt;%= escape_javaScript(@post.title) %&gt;&lt;/h1&gt;").append("&lt;%=escape_javaScript(@post.content) %&gt;");
  </code></pre>
  
  <p>Is this a 3.0 to 3.1 conversion problem?  Can someone point me in the right direction?  </p>
  
  <p>Thanks! </p>