Blog-plugin: How to get author name?

Created on 11 Jul 2015  路  3Comments  路  Source: rainlab/blog-plugin

Hello, great plugin. Only issue i have is, how can i get the name of the user which wrote the blog post?

Most helpful comment

Hello, @mateoprifti!

I am using the following code to get the user name:
{% set authorName = post.user.full_name %}

Hope it helps,
Denis

All 3 comments

+1

Hello, @mateoprifti!

I am using the following code to get the user name:
{% set authorName = post.user.full_name %}

Hope it helps,
Denis

@rendler-denis is correct, you can access the user object of the author that created the post through post.user in Twig.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dnlnrs picture dnlnrs  路  3Comments

marcomessa picture marcomessa  路  7Comments

silasrm picture silasrm  路  4Comments

karnold picture karnold  路  5Comments

rickmills picture rickmills  路  5Comments