= form_for resource, :url => polymorphic_path(resource), :remote => request.xhr? do |f| .errors= resource_error_messages! = render 'form_inner', :f => f .actions = f.submit