Craig Demyanovich wrote:
<%= error_messages_for 'customer' %>
which is telling error_messages_for to display errors for the string
'customer', which I don't expect to ever work, you should probably use
<%= error_messages_for @customer %>
assuming that your controller action sets @customer for use by the view.
that's not the case, could you show us the code for your action?
Thank Craig for the reply. I did as you said but ended up getting error
"@<Customer not allowed" something like this, so I instead did the other
customer = Customer.new
and then: <%=error_messages_for 'customer'%>
it worked but I get ugly underline in customer = Customer.new saying
that customer hasn't been used. Also I have made .css file for the
flash[:notice] but its not getting applied to the generated error
message while it does to other error msgs. By the way the above
mentioned checkout action is exactly as I've put in the controller and
in the view as I've mentioned in my 1st post. Thanks.