Different templates for different authors (4 posts)

  1. alexvaxx
    Posted 5 years ago #

    This may very well be an incredibly easy task but I seem to be unable to do it nonetheless.
    I am looking for the possibility of having different templates for different sets of authors on my blog. To be specific I want two different templates. One for my "editors" where their posts just show up regularly, and another template for my "contributing writers" where a short bio show up before the blog stream. As it is now my default author template is the one with the bio on top and therefore I have had to disable the possibility of clicking on my editors' names to get to their archive page.

    I know it is possible to have different templates for different pages, so the thing I'm asking shouldn't be impossible, I guess.

    Does anyone know how to do this? Am I being clear?

    Thank you very much.


  2. esmi
    Forum Moderator
    Posted 5 years ago #

    What if you combined an author template with the_author_meta and, essentially, had two different layouts based on the_author_meta('user_level')?

  3. alexvaxx
    Posted 5 years ago #

    Thank you, but I think I might ask you to clarify a bit. Are you suggesting I make a conditional statement or what you'd call it? Like "if user level is contributor show this, else show this"? Or?

  4. esmi
    Forum Moderator
    Posted 5 years ago #

    Exactly that. If you can grab the current user's level, you can then compare it against a set user level number (e.g 10 = admin).

Topic Closed

This topic has been closed to new replies.

About this Topic