title: Response from form_for remote not executed
body: <p>I have been scouring different resources to solve this problem, but I can't seem to figure out what the issue might be.</p>
  
  <p>I am trying to do a ajax form processing with jquery.</p>
  
  <p>My application.html.erb contains the following lines</p>
  
  <pre><code>    &lt;%= javascript_include_tag "http://code.jquery.com/jquery-1.6.1.js"%&gt;
      &lt;%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.12/jquery-ui.min.js" %&gt;
      &lt;%= javascript_include_tag "jquery.rails.js" %&gt; 
  </code></pre>
  
  <p><code>jquery.rails.js</code> contains the latest from <a href="https://github.com/rails/jquery-ujs" rel="nofollow">https://github.com/rails/jquery-ujs</a>`</p>
  
  <p>I have the typical form_for call: <code>&lt;%=form_for @data, :remote =&gt; true do |f| %&gt;</code>
  Which trigger the create handler of my controller, since this is a ajax call I have the appropriate <code>create.js.erb</code> which contains a jquery such a <code>$("#data_table").html("something")</code></p>
  
  <p>The whole process works nearly correctly: the ajax called is made correctly, and when I look at the browser developer tool, I see that it returns the correct XHR resource containing the    <code>$("#data_table").html("something")</code> but what it returns is not evaluated by the browser.</p>
  
  <p>I have tried debugging the different scripts, but I couldn't get anywhere meaningful, but I could see that the data return was being process by my <code>rails.jquery.js</code> and <code>jquery.js</code> scripts.</p>
  
  <p>I have found different information around and tried all of them without success. This should be reasonably trivial, but I can't figure it out.</p>