You are here

function gotwo_add_form in Go - url redirects 6

Same name and namespace in other branches
  1. 7 gotwo.admin.inc \gotwo_add_form()

Manually add a go redirect

1 string reference to 'gotwo_add_form'
gotwo_menu in ./gotwo.module
Implementation of hook_menu().

File

./gotwo.admin.inc, line 170
Administrative page callbacks for the gotwo module.

Code

function gotwo_add_form() {
  $form['src'] = array(
    '#type' => 'textfield',
    '#title' => t('Label'),
    '#description' => t('The label used in the go url, this will automatically be made suitable.'),
    '#required' => TRUE,
  );
  $form['dst'] = array(
    '#type' => 'textfield',
    '#title' => t('Destination'),
    '#description' => t('The target url. Can be a relative drupal url or an absolute url.'),
    '#required' => TRUE,
    '#maxlength' => 255,
  );
  $form['submit'] = array(
    '#type' => 'submit',
    '#value' => t('Add'),
  );
  return $form;
}