Very strange observe_form problem


#1

I am doig something very simple here and this is not working correctly.
So any help is greatly appreciated.

I ahve this code in my template:

<% form_for :company_branch, @company_branch, :html => {:id =>
“company_branch_form”} do |f| %>
<%= f.text_field :street1 %>
<%= f.text_field :street2 %>
<% end %>
<%= observe_form(“company_branch_form”, :frequency => 1) %>

The params I get when the form changes is:

{“company_branch_id”=>“1”, “action”=>“edit”,
“controller”=>“admin/company_branches/details”}

This has NONE of the form values. Then when I change the observe_form
line of code to:

<%= observe_form(“company_branch_form”, :frequency => 1, :with => “wtf”)
%>

I get these params:

{“company_branch_id”=>“1”, “company_branch”=>{“street2”=>""},
“action”=>“edit”, “controller”=>“admin/company_branches/details”,
“wtf”=>“company_branch[street1]=1420 Broadwayd”}

It only sends me one of the fields in the proper format and the other
one is assigned to “wtf”.

Any help is greatly appreciated, I have been working on this for hours
and can’t seem to find a solution.


#2

Try posting your question on refwell.com. You might get your answer
there
James

On Feb 4, 9:44 pm, Ben J. removed_email_address@domain.invalid