Displaying 1 result from an estimated 1 matches for "contarct_mail_control".
2012 Jun 30
0
undefined method `xxx_path' for #<#<Class....
...en i try /contact_mail/newi it return me error: undefined local variable
or method `em'' for #<#<Class:0x007fca24248858>:0x007fca21186df0>
model: contact_mail.rg
class ContactMail < ActiveRecord::Base
attr_accessible :email, :message, :name, :subject
end
controler: contarct_mail_controller.rb
class ContactMailController < ApplicationController
def new
@em=ContactMail.new
end
def create
@em = ContactMail.new(params[:contact_mail])
@em.save
end
end
view: new.html.erb
<%= form_for(@em) do |f| %>
<div class="field">
<%= f.label...