You are here

function emfield_disable_obsolete_provider in Embedded Media Field 6.3

Same name in this branch
  1. 6.3 emfield.admin.inc \emfield_disable_obsolete_provider()
  2. 6.3 deprecated/emfield-deprecated.admin.inc \emfield_disable_obsolete_provider()
Same name and namespace in other branches
  1. 6.2 emfield.admin.inc \emfield_disable_obsolete_provider()
1 string reference to 'emfield_disable_obsolete_provider'
_emfield_deprecated_menu in deprecated/emfield-deprecated.inc
Implementation of hook_menu().

File

deprecated/emfield-deprecated.admin.inc, line 259
The administrative settings page.

Code

function emfield_disable_obsolete_provider($module = NULL, $provider = NULL) {
  if ($module && $provider) {
    $providers = emfield_system_list($module, $provider, array(
      'suppress_errors' => TRUE,
    ));
    if (!isset($providers[$provider])) {
      variable_set('emfield_' . $module . '_allow_' . $provider, FALSE);
      drupal_set_message(t('The message regarding the missing or obsolete Embedded Media Field %provider provider file has been disabled. Note that if you decide in the future to install the provider, you will need to re-enable it at the !admin page.', array(
        '%provider' => $provider,
        '!admin' => l(t('Embedded Media Field configuration'), 'admin/content/emfield'),
      )));
    }
  }
  drupal_goto($_GET['destination']);
}