You are here

function semanticviews_get_alias_tokens in Semantic Views 6

Helper function that returns an array with field aliases as key and the field tokens as values.

See also

views_handler_field::get_render_tokens()

1 call to semanticviews_get_alias_tokens()
template_preprocess_semanticviews_view_unformatted in ./semanticviews.theme.inc
Display the simple view of rows one after another

File

./semanticviews.module, line 22
semanticviews.module TODO: Enter file description here.

Code

function semanticviews_get_alias_tokens($view) {
  $tokens = array();

  // Now add replacements for our fields.
  foreach ($view->display_handler
    ->get_handlers('field') as $name => $handler) {
    $tokens[$handler->field_alias] = "[{$name}]";
  }
  return $tokens;
}