You are here

function mediafront_features_export_render in MediaFront 6

Same name and namespace in other branches
  1. 6.2 includes/mediafront.features.inc \mediafront_features_export_render()
  2. 7.2 includes/mediafront.features.inc \mediafront_features_export_render()
  3. 7 includes/mediafront.features.inc \mediafront_features_export_render()

Implementation of hook_features_export_render().

File

includes/mediafront.features.inc, line 25

Code

function mediafront_features_export_render($module_name, $data) {
  $items = array();
  foreach ($data as $key) {
    $preset = mediafront_get_preset($key);
    unset($preset['pid']);
    $items[$key] = $preset;
  }
  $code = "  \$items = " . features_var_export($items, '  ') . ";\n";
  $code .= '  return $items;';
  return array(
    'mediafront_default_presets' => $code,
  );
}