You are here

function publishcontent_config_form_post_submit in Publish Content 7

Form submission function.

This runs after the quick publish form has been saved. If the quick publish method changed then the site cache is flushed.

1 string reference to 'publishcontent_config_form_post_submit'
publishcontent_config_form in ./publishcontent.admin.inc
Administration settings form.

File

./publishcontent.admin.inc, line 65
Contains page callbacks for publishcontent

Code

function publishcontent_config_form_post_submit(&$form, &$form_submit) {
  $old_mode =& drupal_static('publishcontent_config_form_mode');

  // If the quick access mode changed then flush all caches.
  if ($old_mode != $form_submit['values']['publishcontent_method']) {
    drupal_flush_all_caches();
    drupal_set_message('All site caches have been cleared.');
  }
}