Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By Falcox on
Hi,
I'd like to add more than one author for some nodes. However, when I add many authors in the default author field in Drupal 8, it just saves one author, not all, by the end.
I know that it is possible to create a new field that would be a user reference field, and to assign to it unlimited values, but I find it dumb to create a field when there is already one by default.
Is it possible to change the default author field to add more than one author ?
Thanks.
Comments
The simple answer is no. The
The simple answer is no. The database table for nodes has a single value column for the User ID (UID), so a node cannot handle multiple authors.
You could override this by creating a new table for authors that has a unique key, then in the UID column store a reference to that unique, but then you'd have to add the authors when loading, and any module that relies on the author ID would break, and potentially core issues would arise as well. You'd be bug hunting a lot.
Better to use the entity reference to other authors.
OK thx for your answer. I
OK thx for your answer. I think I'll create a user reference field that can take unlimited values. It will be easier !
Create view block for 'Author'
Hi,
Can you please explain how to create a block for showing the content of type Author in the node page.
You would have a better chance when ...
creating a post for yourself on the right board: Post Installation.