다음과 같은 formtastic 양식이 있습니다 :formtastic 형식으로 필드 유효성 검사 오류 메시지를 표시하려면 어떻게합니까? remote => true?
= semantic_form_for @record, :remote => true, :id => 'my_form', :url => ...
사용하고 있습니다 : 원격 => 사실, 자바 스크립트에서 컨트롤러 응답을 처리합니다.
$('#my_form')
.bind("ajax:beforeSend", function(evt, xhr, settings){
})
.bind("ajax:success", function(evt, data, status, xhr){
$('#response').append(xhr.responseText);
})
.bind('ajax:complete', function(evt, xhr, status){
});
With : remote => false, my form은 자동으로 필드 유효성 검사 오류를 표시합니다. 예를 들어, 다음과 같이 formtastic 필드 유효성 검사 오류를 표시하려면 어떻게해야합니까? 응답 자바 스크립트에서 자신을 처리?
감사합니다. 멋진 보석을 언급 해 주셔서 감사합니다 .-) 매력 작품처럼 :-) +1 :-) –