I am a bit of a loss to understand what you are doing here, though
this may be my problem rather than yours. As I understand it
error_messages_for is displays the errors associated with the given
variable. If quotation is nil how can it have errors associated with
it? You have not described what you are doing to generate some errors
that you would like to display. Presumably this is as a result of
submitting the form that is being generated, if so what are you doing
to get the invalid object back to the displayed page so its errors can
be displayed?
You need to write some javascript/rjs to (after form submission)
render a partial (which displays errors in whatever way you want) and
insert that into the appropriate part of the DOM
If you're returning RJS or the like from the AJAX call, the method I'd
use would be to wrap the error_messages_for in a div and send back a
page.replace call that fills it out. I've used this in a couple
production apps without problems.