You are here

function domain_conf_delete_variable in Domain Access 7.3

Delete a setting from {domain_conf}.

Parameters

$domain_id: The unique domain ID that is being edited.

$variable: The name of the variable you wish to delete.

2 calls to domain_conf_delete_variable()
domain_settings_form_submit in domain_settings/domain_settings.module
Submit handler for domain-specific settings.
drush_domain_conf_set in domain_conf/domain_conf.drush.inc

File

domain_conf/domain_conf.module, line 443
Domain manager configuration options.

Code

function domain_conf_delete_variable($domain_id, $variable) {

  // Get the current settings for this domain, if any.
  $settings = domain_conf_data_get($domain_id, TRUE);

  // Settings found, remove them.
  if (!empty($settings)) {
    unset($settings[$variable]);
    domain_conf_data_set($domain_id, $settings, FALSE);
  }
}