function views_api_features_export_render in Features 6
Implementation of hook_features_export_render(). Adds the views mothership hook, views_api().
File
- includes/
features.views.inc, line 28
Code
function views_api_features_export_render($module, $data) {
$values = array();
foreach ($data as $component) {
$split = explode(':', $component);
if (count($split) === 2) {
list($key, $value) = $split;
$values[$key] = $value;
}
}
$code = ' return ' . features_var_export($values, ' ') . ';';
return array(
'views_api' => $code,
);
}