You are here

function record_shorten_clear_all in Shorten URLs 7

Same name and namespace in other branches
  1. 6 record_shorten.module \record_shorten_clear_all()
  2. 7.2 record_shorten.module \record_shorten_clear_all()

Clear all records form.

1 string reference to 'record_shorten_clear_all'
theme_record_shorten_records in ./record_shorten.module
Builds a list of shortened URLs.

File

./record_shorten.module, line 66
Records shortened URLs.

Code

function record_shorten_clear_all($form, $form_state) {
  $form['warning'] = array(
    '#markup' => '<p><strong>' . t('Warning: there is no confirmation page. Cleared records are permanently deleted.') . '</strong></p>',
  );
  $form['note'] = array(
    '#markup' => '<p>' . t('Note: clearing records does not clear the Shorten URLs cache.') . ' ' . t('Also, URLs already in the cache are not recorded again.') . '</p>',
  );
  $form['clear'] = array(
    '#type' => 'submit',
    '#value' => t('Clear all records'),
  );
  return $form;
}