You are here

function enterprise_fields_blog_author in Enterprise Base 7.3

1 string reference to 'enterprise_fields_blog_author'
enterprise_fields_ds_fields_info in enterprise_fields/enterprise_fields.module
Implements hook_ds_fields_info().

File

enterprise_fields/enterprise_fields.module, line 95

Code

function enterprise_fields_blog_author($variables) {
  if (module_exists('enterprise_user')) {
    $entity = $variables['entity'];
    $name = $entity->realname ? $entity->realname : $entity->name;
    $output = l($name, 'resources/blog/' . enterprise_base_create_machine_name($name, '-'), array(
      'attributes' => array(
        'class' => array(
          'name',
        ),
      ),
    ));
    return $output;
  }
}