abuse_warn_form

Definition

abuse_warn_form($object, $op)
abuse/abuse.module, line 734

Code

<?php
function abuse_warn_form($object, $op) {
  $form = array();
  $form['object_type'] = array(
    '#type' => 'value',
    '#value' => $object->type
  );
  $form['object_oid'] = array(
    '#type' => 'value',
    '#value' => $object->oid
  );
  $form['subject'] = array(
    '#type' => 'textfield',
    '#title' => t('Warning subject'),
    '#default_value' => t(variable_get('abuse_warn_subject', '')),
    '#cols' => 72,
    '#rows' => 10,
    '#required' => TRUE,
  );
  $form['body'] = array(
    '#type' => 'textarea',
    '#title' => t('Warning body'),
    '#default_value' => t(variable_get('abuse_warn_body', '')),
    '#size' => 72,
    '#required' => TRUE,
    '#description' => t('available fields are !title, !url, and !name')
  );
  $form['warn'] = array(
    '#type' => 'submit',
    '#value' => t('Warn and '. ucfirst($op))
  );
  $form['cancel'] = array(
    '#type' => 'submit',
    '#value' => t('cancel')
  );
  return $form;
}
?>