• Hi,

    I have updated my Biographical Info for the user but this doesn’t show up when I click on the author name. It takes me to this page: https://www.uxstudent.co.uk/author/william-deng/ but all that happens is that the text “Author: William Deng” is displayed. There is no picture or information.

    Does anyone know how to fix this?

    Many thanks!

Viewing 8 replies - 1 through 8 (of 8 total)
  • Moderator Kathryn Presner

    (@zoonini)

    The author archive page displays all posts by a particular author, it doesn’t display a bio or photo.

    If you’d like to add that, it would require creating a child theme with some theme-file modifications in it.

    Before I guide you though that, could you let me know if what you would like to appear on each author page is:

    – The title Author: Author’s Name, followed by
    – The author’s bio and Gravatar, followed by
    – The author’s posts

    If that’s your goal and you’re comfortable trying a child theme, let me know and I can point you in the right direction.

    Thread Starter absurdity69

    (@absurdity69)

    Hey Kathryn,

    I’m comfortable with child themes. I’d like:

    – The title Author: Author’s Name, followed by
    – The author’s bio and Gravatar, followed by
    – The author’s posts

    May you please give me some pointers?

    Many thanks
    Will

    Moderator Kathryn Presner

    (@zoonini)

    Cool, once you set up your child theme copy the archive.php file from the parent and place it in the child.

    You’ll then need to add a conditional piece of code that only runs on author archive pages. You’ll add the author bio code itself inside the condition.

    I borrowed the author bio from Twenty Fifteen and made a couple of adjustments, you can check it out here:

    https://gist.github.com/kathrynwp/9b7ea205ee3c0d812ba5758178fd70f0

    Put this code in your child theme’s archive.php file just after the closing header tag on line 78.

    You’ll also probably want to add some CSS to style the bio how you want it to look in your child theme’s style.css file – you can use the classes you see in the PHP file, like author-avatar etc. If you need help with that part too, just let me know. Without any added CSS styles, it should look something like this:

    Kathryn P Minnow Child 3 1 0 0 by Anonymous

    Thread Starter absurdity69

    (@absurdity69)

    I’m very grateful for your help Kathryn.

    Thanks, I will try this now let you know how it goes.

    Thread Starter absurdity69

    (@absurdity69)

    Okay it didn’t work for me but there’s issues:

    – Abit amateur but I don’t know how to set up an archive.php in my child theme so instead I dumped the code in the minnow theme’s archive.php, like here:

    Add author code in my archive.php
    https://imgur.com/a/Se3ON
    I save it and this is blank: https://www.uxstudent.co.uk/author/william-deng/

    Could you help me further Kathryn?

    Thank you.

    • This reply was modified 8 years, 5 months ago by absurdity69.
    • This reply was modified 8 years, 5 months ago by absurdity69.
    Thread Starter absurdity69

    (@absurdity69)

    To debug further, I switched over to the main Minnow theme which is where I put the author code into its archive.php.

    I go to /author/william-deng/ and I get this error:

    Parse error: syntax error, unexpected $end in /home/thegizgp/public_html/uxstudent.co.uk/wp-content/themes/minnow/archive.php on line 130

    I just checked line 130 is the end of the code and it has this: <?php get_footer(); ?>

    Have I f*@ked things up? ??

    Thread Starter absurdity69

    (@absurdity69)

    Edit: Typed this in error.

    • This reply was modified 8 years, 5 months ago by absurdity69.
    • This reply was modified 8 years, 5 months ago by absurdity69.
    Moderator Kathryn Presner

    (@zoonini)

    Hi there – I’m sorry that I seem to have missed these replies.

    Abit amateur but I don’t know how to set up an archive.php in my child theme

    You make a copy of archive.php from your parent theme and place it in your child theme folder. Your child theme’s copy of the file now overrides that of the parent.

    Could you upload a copy of your modified archive.php somewhere so I can download it and have a look directly? Or you can copy-paste the entire thing into a Pastebin and link it here. https://pastebin.com/

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Clicking on AUTHOR shows blank space’ is closed to new replies.