You are here

function ajax_comment_ajax_validate_pass in Ajax 6

Validation cleanup procedures

Parameters

$form Assoc:

$form_state Assoc:

$data Assoc:

Return value

Bool

File

plugins/comment/ajax_comment.module, line 52

Code

function ajax_comment_ajax_validate_pass(&$form, &$form_state, &$data, &$pass) {
  if ($form['form_id']['#value'] === 'comment_form' && $form['#post']['op'] === t('Preview')) {
    $data['preview'] = ajax_comment_preview($form, $form_state);
    $pass = FALSE;
  }
  return TRUE;
}