title: HAML - how to call a form with a selector?
body: <p>I have this form in HAML:</p>
  
  <pre><code>= form_for([:mobile,@disclosure], :html =&gt; {:id =&gt; "add_validation_to_ajax_form", :remote =&gt; true}) do |f|
  </code></pre>
  
  <p>but the add_validation_to_ajax_form function has a a parameter like this:</p>
  
  <pre><code>function add_validation_to_ajax_form(form_selector){
      alert ("hello :)");
      add_custom_validation_methods();
      $(form_selector).submit(function(event) {
        force_ckeditor_to_update();
      }).validate({meta:"validate",onkeyup:false,validClass:"ok-input",
            errorPlacement: function(error, element) {
  
            }
        });
  }
  </code></pre>
  
  <p>And I am new to the HAML syntax of how it is supposed to call the JavaScript function.  Right now when the form is submitted, this function is not displaying the hello popup.  Any idea why it isn't working?</p>
  
  <p>Thanks!</p>