You are here

function theme_hosting_feature_dependencies in Hosting 6.2

Same name and namespace in other branches
  1. 7.4 hosting.features.inc \theme_hosting_feature_dependencies()
  2. 7.3 hosting.features.inc \theme_hosting_feature_dependencies()

Theme function to display Hosting feature dependencies.

1 theme call to theme_hosting_feature_dependencies()
hosting_features_form in ./hosting.features.inc
The Hosting features form.

File

./hosting.features.inc, line 354
Include for functionality related to Hosting module features.

Code

function theme_hosting_feature_dependencies($dependencies, $prefix, $features) {
  $return = "<div class=\"admin-required\">{$prefix}:";
  $last = end($dependencies);
  reset($dependencies);
  foreach ($dependencies as $module => $require) {
    $return .= ' ' . $features[$require]['title'];
    $enabled = $features[$require]['enabled'] ? 'enabled' : 'disabled';
    $return .= " (<span class=\"admin-{$enabled}\">";
    $return .= $enabled;
    $return .= '</span>)';
    $return .= $require == $last ? '.</div>' : ',';
  }
  return $return;
}