Ruby on Rails Tuesday, November 12, 2013

Hi guys,

I am battling with the weirdest problem ever. I'm using rails 3.2.13 and trying to submit a form remotely and it keeps getting processed as HTML. I have the correct line in my application.js file namely:
#= require jquery
#= require jquery_ujs

I have the correct line in my form:
= simple_form_for :non_member_applcation, url: :non_member_applcation, remote: true, :html => {:id => "non-member-application", multipart: true} do |f|

I  have the correct route:
match '/non_member_applcation' => 'jobs#non_member_applcation', as: :non_member_applcation
 
but when I click submit it just won't work.

Also note that the form is in a modal, but I have done something similar to this before and it worked just fine. Any thoughts? Thanks
 

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/a51651d3-8750-4eb5-b9a8-872c2ed6b493%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment