i have a site where I use display suite for custom page display. And all works. Now I need to add a custom field formatter for the "Author" field, but I don't find how to link "author" to a new field formatter.

I know that I need to use hook_field_formatter_info() but I don't understand which is the right value for "field types". I have tried with "user", "user_reference", "text","author" but nothing.

I have tried to see how Display Suite define its fields formatter, but for this field the module use "2" for this value:

$fields['node']['author'] = array(
    'title' => t('Author'),
    'field_type' => DS_FIELD_TYPE_FUNCTION,
    'function' => 'ds_render_author_field',
    'properties' => array(
      'formatters' => array(
        'author' => t('Author'),
        'author_linked' => t('Author linked to profile')



So how can I add one new field formatter for the author field ?



1 Answer 1


I have found the solution: I have to create a new display suite formatter because that page use ds for the display.

I have read this:

Creating custom display suite fields or how I learned to stop worrying and use hook_ds_fields_info()

and I have created my formatter. All works. Thanks for all to all.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.