WP plugin: Get Author Profile

posted on January 31, 2005  (Update: January 12, 2006)

Get Author Profile is a pretty basic WordPress plugin that lets you manually access an author’s (i.e. user’s) profile. The main purpose is to let you provide author information outside The Loop, such as for a sidebar intro of the blog owner or to list contributors to your blog.

(Note to WordPress 1.2 users: This is now a WordPress 1.5+ plugin. See the July 9th update.)

When the get_author_profile() function is called with a specific numeric User ID, you can make use of global variables related to that author’s profile, or alternatively display their information with the function author_profile().

Usage:

<?php get_author_profile(auth_ID); ?>

Usage notes: To get information on more than one user profile, simply run get_author_profile() again with another user ID to reset the author variables (but only after you’re done with the previous profile info!). get_author_profile() is “author template aware,” so if you drop it in a theme’s author.php without providing a user ID, it will set the user variables to the ‘current’ user.

Parameter:

auth_ID
(integer) Numeric user ID of a specific author. This is the “ID” number found under the Users administration page. This then enables the following global variables:

  • $author_aim (AOL Instant Messenger ID)
  • $author_displayname (display format selected under Users > Profile)
  • $author_email
  • $author_firstname
  • $author_icq (ICQ number)
  • $author_jabber (Jabber/Google Instant Messenger ID – WP 2.0 only)
  • $author_lastname
  • $author_level
  • $author_login
  • $author_msn (Microsoft Instant Messenger ID)
  • $author_nicename (login in url encoded format)
  • $author_nickname
  • $author_posts (post count)
  • $author_posts_link (URL to all posts)
  • $author_profile (Profile/”About yourself”)
  • $author_url (“Website”)
  • $author_yim (Yahoo Instant Messenger ID)

Also in the mix is the following template tag:

<?php author_profile('authcase', display); ?>

You can use this after get_author_profile() has been called in your template to display various author profile elements without having to echo the variables. The ‘authcase’ (first) parameter accepts:

authcase
(string) Type of infomation to display. Valid values duplicate variables from above:

  • 'aim'
  • 'displayname'
  • 'email'
  • 'firstname'
  • 'icq'
  • 'jabber'
  • 'lastname'
  • 'level'
  • 'login'
  • 'msn'
  • 'nicename'
  • 'nickname' (Default)
  • 'posts'
  • 'posts_link'
  • 'profile'
  • 'url'
  • 'yim'

The display (second) parameter takes either TRUE (display or echo the value) or FALSE (return the value for use in other PHP code). Defaults to TRUE.

Example:

<?php get_author_profile(1); ?>
<div class="profile">
  <ul>
  <li id="myprofile">Blog Owner:
    <ul>
    <li><?php author_profile('firstname'); ?> <?php author_profile('lastname'); ?></li>
    <li>Jabber: <?php author_profile('jabber'); ?></li>
    <li>AIM: <?php author_profile('aim'); ?></li>
    <li>Notes: <?php author_profile('profile'); ?></li>
    </ul>
  </li>
  </ul>
</div>

Update [Jan-12-2006] 0.5.1 – Bug fix to get_author_profile() when no author is passed as an argument (i.e. author queries).
Update [Jan-08-2006] 0.5 represents changes to run under WordPress 2.0 (should still work in 1.5.x). Only thing notably new (outside code changes and additions) are three variables: $author_jabber (author_profile(‘jabber’)), $author_nicename (author_profile(‘nicename’)) and $author_displayname author_profile(‘displayname’)). $author_displayname is the name format users select under “How to display name” on the Users control panel. A few profile elements were removed in WordPress 2.0, these being the MSN IM and ICQ fields. However, if you upgraded from a previous version of WordPress these will be retained in your users’ data (technically, in the new usermeta table).
Update [Jul-11-2005] 0.4 adds a new parameter to author_profile(): display. Information above edited to reflect that. Not sure why I left something like that out originally…
Update [Jul-09-2005] 0.3 Fixes problems with the plugin in WordPress 1.5. This version is also author template aware, meaning you can use get_author_profile() in an author.php theme template without an user ID, and it will set the author variables dynamically for the ‘current’ author. This is now a WordPress 1.5+ plugin. For WordPress 1.2 users, version 0.2 is here.

Author: Kaf Oseo
Categories: WordPress
Comments: (103) · Leave a comment · Comments RSS2

Carlos
Comment » March 11, 2005 @ 8:49 am

Hi this is exactly what im looking for. Im building a modification of WordPress 1.5. But i have problems on how to get the ID of the user logged in. Is it stored in a cookie or a global variable? I want to build a custom profile for the users on my blog. And therefore i must list all the user information in the fields. Any suggestions? //Carlos

Kaf
Comment » March 12, 2005 @ 1:59 pm

It’s available through the get_currentuserinfo() function. Just running this provides a number of global variables:

$userdata
$user_level
$user_ID
$user_nickname
$user_email
$user_url
$user_pass_md5

hans
Comment » April 7, 2005 @ 11:52 pm

Just wanted to know if this work with version 1.5?

hans
Comment » April 8, 2005 @ 1:47 am

Ok…it seems to be working for WP1.5;

Anyway, what if I am posting and wish to create a link to show a profile page of another user? For example:
Kafkaesqu� �has a get author profile plugin…

Kaf
Comment » April 9, 2005 @ 12:53 pm

hans, WordPress can auto-generate a link to all posts of any author (on your blog):

http://codex.wordpress.org/Template_Tags/the_author_posts_link

Also, you can pretty easily set up a profile of each author in 1.5 by creating an author.php template for your theme, and either setting up a bit of php with my plugin at the top of that page before the posts, or through this method:

http://wordpress.org/support/topic.php?id=27554#post-154787

rob
Comment » April 21, 2005 @ 6:24 pm

Is there any way to get the auth_ID from the incoming link? For example when sombody clicks on an author link – it takes them to the archives.php page – and the title of the page is “author archives” – however i want it to have the actual name of the author in the title of the page. Thanks

Kaf
Comment » April 21, 2005 @ 8:24 pm

Rob, just follow the WordPress support forums link above your comment. I lay out there how to assign the user ID based on the author query (don’t even need my plugin for it).

Tamara
Comment » May 2, 2005 @ 10:29 am

i can not get a pro file enny where ellls

Tim
Comment » May 8, 2005 @ 1:21 pm

Hi, I cannot use your plugin because of the following reason (I’m new to WordPress):

First of all, I didn’t understand how to get an author’s name outside the Loop for ex. First, I install and run the plugin and after I create a php file and put this code in it:

This is for the author with the ID 10, right?

Sorry if I’m getting all these wrong, but that’s what I tried to do. After getting the author’s name, I’ll need his e-mail, his posts (with links) and his description. Can you help me on how to setting all these clearly? Because I didn’t understand well how to make work this plugin.

Thanks a lot.

Tim
Comment » May 8, 2005 @ 1:22 pm

The code didn’t show up, here it’s:

Tim
Comment » May 8, 2005 @ 1:23 pm

Once again, sorry :)

<?php get_author_profile(auth_10); ?>

Kaf
Comment » May 8, 2005 @ 1:49 pm

Tim, as long as you meant 10 when you wrote auth_10, then it will initialize the plugin’s variables/functions to display profile information for that author (ID: 10). See the example above for how to display the various author info.

If you’re looking for a comprehensive way to display authors’ profile info with their posts, in WordPress 1.5 you can create an author template (author.php) in your active theme, along with the following code (instead of my plugin):

http://wordpress.org/support/topic/27554#post-154787

Or you can use a combination of plugin and template. Depends on how you want to arrange the information.

heather
Comment » July 1, 2005 @ 9:04 am

Hello Kafkaesquí, thank you for your inredible help on the forums with author templates. I used the bulk of it to make a new page in the codex. I credited you for it when I linked to your plug in.

But… I’m unclear about something– the use of the author data on other archive templates. I’ve never done it, but I guess it should be included in the documentation. Rather than paste the draft documentation here, would you mind to look in the codex and just say whether or not this is accurate?

In Codex: Including_Author_data_on_other_templates

Thanks very much.

oso
Comment » July 31, 2005 @ 5:45 pm

Brilliant. Thank you so much. Though I was able to hack around it, including the author’s rss feed woulda been an extra bonus.

Janine
Comment » August 24, 2005 @ 2:52 am

I’m trying to set up a group blog for my roommates, and I want to put their profiles in the side bar. My current code looks like this:


<?php get_author_profile(auth_3); ?>
<div class="profile">
<ul>
<li id="myprofile">Name:
<ul>
<li><?php echo $author_firstname . " " . $author_lastname; ?></li>
<li>Email: <?php echo $author_email; ?></li>
<li>AIM: <?php echo $author_aim; ?></li>
<li>Notes: <?php echo $author_profile; ?></li>
</ul>

And no information comes up if you look at the sidebar at http://chickenrap.wirepipe.net. What am I doing wrong?

Thanks.

Richard
Comment » August 28, 2005 @ 10:41 pm

I am trying to get my icq and msn number to dispaly in my template. I thought that this plugin would do that but it is not. Is this for the admin or just the visitors to my site.

ps I have all of the variables n my template

Erik
Comment » October 10, 2005 @ 2:25 pm

Im currently building a blog for me and my friends. At the topp I’ve got Links to the blog, the gallery, Contact and profiles. When clicking the profile link I want to list All the users with their data. I’ve tried with this plugin, but it didnt work. Can’t i just make a author.php file and have for eksample :

Brian Bonner
Comment » October 30, 2005 @ 6:19 pm

I am looking to just provide a link to the users profile. Any ideas? Also, is there a way to make the author’s name a link to their profile?

Olaf
Comment » December 28, 2005 @ 5:09 pm

It seems, that Get Author Profile doesn’t work with WordPress 2 :(
I think it’s because of the new structure of the database.

Kaf
Comment » December 28, 2005 @ 11:21 pm

I think it’s because of the new structure of the database.

Yep. I’m currently rethinking how the plugin should work because of the new usermeta table, etc.

Olaf
Comment » December 29, 2005 @ 9:14 am

Thank you.
I hope there will be a new version soon.

Nitallica
Comment » January 2, 2006 @ 10:10 pm

Oh good, I’m glad it’s not just me seeing that problem, LOL. Looking forward to a new version, fix, or what-have-you. :)

(I’m pretty pleased so far that this is my only real “snag” since upgrading this morning!)

Kaf
Comment » January 8, 2006 @ 8:05 pm

Just a comment note that Get Author Profile should now work in 2.0. Sorry ’bout the delay everyone. Just blame it on another plugin

Sandra
Comment » January 11, 2006 @ 6:09 pm

I posted your example code listed on this page after “The display (second) parameter” in the sidebar.php and it worked but of course it put author id 1 info on every author page. I tried using “< ?php get_author_profile(); ?>” (sans quotes) and it produced an error.

What am I doing wrong?

Kaf
Comment » January 12, 2006 @ 5:49 am

Sandra, you did nothing wrong. Well, other than run into a bug, which is not your fault. Grab the latest version of the plugin (0.5.1), which fixes it.

Hyuga
Comment » January 20, 2006 @ 2:05 am

Useful plug-in–I appreciate it as it saves me from the tedium of having to do this myself.
One quick question: Is there any reason it doesn’t provide a variable such as $author_registered? I needed this, so I just added it myself no problem. I just wondered if there was a good reason that it weren’t already there.

J. Siefer
Comment » January 24, 2006 @ 5:31 pm

Sorry if I am being redundant here, but how can I display current user information (other than dropping the code into the theme’s author.php.) I don’t want to put in a specific user ID. I just want it to display who is logged in. Thanx much. YOUR PLUGIN ROCKS MY FACE OFF!

J. Siefer
Comment » January 25, 2006 @ 1:35 pm

Sorry about the question (as it was already kind of discussed). I was just looking for an example more or less. If anybody else is wondering on the get user level script, an example is at: http://codex.wordpress.org/get_currentuserinfo

trevor
Comment » February 10, 2006 @ 5:49 pm

That’s cool – does all the long stuff I’d written for 1.5 much quicker. Question: how would you call info for all authors on the blog in order to be able to provide a group page?

andrea
Comment » February 14, 2006 @ 5:08 pm

When I activate the plug in, my wp-login.php page won’t render. As soon as I deactivate it, the page displays again. HELP! I really want to use this plug in.

andrea
Comment » February 15, 2006 @ 12:27 pm

BTW, I am using WP 1.5.2

Brendan
Comment » February 16, 2006 @ 2:30 am

how do i grab the author ID if I wanted to display that? I’m setting up a staff page for my site using this plugin and want to display the user’s ID number, so the get_currentuserinfo command won’t work.

Brendan
Comment » February 23, 2006 @ 3:57 pm

hello? i’d really like some help on this.

Kaf
Comment » February 28, 2006 @ 3:25 pm

Andrea, I think I sent you an email on this. Let me know if you never received it.

Brendan, it would help to know *how* and *when* you need the user ID. If this staff Page (which I’m assuming is a Page in WP’s framework) will list all users, see my All Author’s Page template, found here:

For WordPress 1.5:
http://guff.szub.net/source/page-authors.php

For WordPress 2.0:
http://guff.szub.net/source/page-authors-2.0.php

For info on Page templates:
http://codex.wordpress.org/Pages#Page_Templates

If this is *not* what you’re attempting to do, it’s helpful if you provide some details.

Chris
Comment » March 23, 2006 @ 1:30 pm

Been trying to make registered users comments link to their profile, I see that Brian asked this question some time ago. Well, I found your comment over at WordPress, Trouble with post_link….

Now I’ve got it working in the sidebar, but only for a static auth_ID. I know next-to-nothing about PHP, and so far have this much:

<?php get_author_profile(); ?> <a href="<?php author_profile('posts_link'); ?>"><?php author_profile('nickname'); ?></a>

Any help is much appreciated.

Kaf
Comment » March 26, 2006 @ 12:47 pm

Chris, within the comment loop you should be able to use $comment->user_id for the user ID of the current commenter. On comments from those who are not registered (or not logged in when commenting) it returns null or 0, so you may want to test on it first before using it with get_author_profile() like so:

<?php get_author_profile($comment->user_id); ?>

tylerwillis
Comment » April 11, 2006 @ 3:57 pm

Kaf,
Great plugin, I’ve been using it for a while now. I just noticed that upgrading to 2.0 seems to have killed the posts_link function I had called on my about page.
The link that the posts_link call generates looks like /author/someone/ when I hover over it, but clicking on it leads to /author/ – and that’s a 404 page.
I’ve left it up for the moment at http://www.tylerwillis.com/about/ – you can see it being used in the staff table.
I’m not sure what happened, why it stopped working. If you have any thoughts, I’d appreciate them.
Tyler

Philippe
Comment » April 13, 2006 @ 4:54 pm

Hi,

simple questions:
where do I put this file (for wp 2.0) ? in which folder?
I cant seem to find the answer

do I need to modify it ?

cid
Comment » April 14, 2006 @ 3:39 am

Hi,

I just upgraded to WP2.0.2 from 1.5.2, and I can’t seem to use html to make some parts of my profile italicized or underlined. Is this something in the plugin that I’m forgetting to enable?

Paul Reid
Comment » April 29, 2006 @ 8:44 am

I’m using a WordPress 2.0 template called Alexified to run a multi-user blog. http://www.digitalchalkie.com/

I’d like readers to be able to click on a post authors name and be taken to an “archives/author/User” page.

The K2 template does this automatically eg. http://www.paraburdoo.det.wa.edu.au/

Any suggestions much appreciated.

Paul

casey
Comment » May 30, 2006 @ 10:51 pm

Is there some way to use a link to pass the page (author.php) and the author_ID (author=51) and get the profile info for that user? It seems like everything has to either be all authors or hard-codes the author id…
I’d be happy to do this with a category template (I want posts, too) or the author.php file. Right now, I can call a custom category template and pass a specific author_ID (author=#) and get posts for only that author to display.
Now, how can I use the passed value for author_ID to retrieve that author’s profile data?

Micke Mus
Comment » June 8, 2006 @ 8:34 am

Hey Kaf.. I love the page-authors.php!! Solved all my problems.. I was using the “User Bio Popup” by Aleister but that kept on breaking so that all letter G (capital) brought up a user (same one everytime). I have one question though! Any clue how I can replace the get_author_image with the users gravatar instead. I’m using the “Gravatars2″ plugin (by Kip Bond) which caches gravatars for my site?

Tx again Guru!!!

Robert Hartl
Comment » July 13, 2006 @ 11:43 am

Thanks for Your all-author-template. It works very well as You can see in modifications on Autoren Wirtschaftsbrief.

I want use Your sensefull if-rules an the template author.php too.
How must be the beginning? Because foreach… isn’t, because there’s no loop (only fpr articles of the aithor by WP).
Thanks a lot.

Terry Heath
Comment » September 5, 2006 @ 1:16 pm

Thanks for the plugin, it was a great solution for the new site I’m building. It was a good way to make an “About the Author” box for entries in a multi-author site. Since it pulls the info right out of their user profile that saves a lot of time!

david
Comment » September 26, 2006 @ 12:43 am

I am trying to put te nickname of the currently displayed author page into a php-enabled widget. I tried the get-author-profile plugin and also some stuff like:

If the above fails to work for you, another option for WordPress 1.5 or above is the following:

get_queried_object();
?>

But no joy! How do I put the author page nickname into a widget / template if it is outlide of the loop?

david
Comment » September 26, 2006 @ 1:09 am

Answering my own question :)

nickname; ?>’s

ovidiu
Comment » October 23, 2006 @ 5:33 am

hello,

I am curios if someone could point me to a small howto or give me some indications on how to achieve the following:

I want to modify my sidebar accordingly to what is being displayed. I.e. if someone is reading a post the sidebar should display some small info about the author of that particular post, like username, nickname, some details that the author ca fill in in his profile.
If someone is reading a page or just browsing through a category, I do not want this info displayed.

how would I go ahead to achieve this?

Michael Pollock
Comment » October 25, 2006 @ 12:53 pm

hey Kaf:

great plugin. thanks alot. i’m using the allauthors.php page, and i’d like to use html in the author description. have tried a few different was but can seem to make it work. current, i have the following:


description)
Tests for and displays user description (i.e. Profile).
*/
?>
description) : ?>
description; ?>

Is there any way I can tweak that to make it display HTML.

Thanks – Michael

UPDATE: Figured it out. I’m using this and it works:

description); ?>

Thanks again – Michael

Phej
Comment » November 17, 2006 @ 6:06 pm

Kaf,
Thanks for a great plugin! Is there a way to use this plugin to display info on every “Author” in the db without having to have an entry for each user id?

Thanks!

Daniel
Comment » November 19, 2006 @ 7:46 pm

thx a lot for the author plugin. we use it at our blog at university and it is very useful to create different student / semester profiles.

Eka
Comment » December 22, 2006 @ 5:08 am

Hi, I’ve just installed your plugin and found it very useful.
I am sorry to be so much of a trouble, but as Phej above suggested, is there any possible way to loop the thing for all authors?
I tried combining it w your All Page Authors template (http://guff.szub.net/source/page-authors-2.0.php) but as I know hardly any PHP, it didnt work.
Thankyou very much for your help.

Saman Sadeghi
Comment » January 11, 2007 @ 2:34 pm

This plug is a great idea!

I would like to display the author’s profile in the sidebar on that author’s posts only. So, if the current post is written by author “Steve” who’s id = 4, then post his profile in the sidebar.

The problem I am having is how to read the author’s ID. WordPress would need to find the author’s ID of the current post and display the correct profile – I need this because there are multiple authors.

This is separate from a author.php page. I tried this but it doesn’t work (I realized the brackets are wrong, I did it so the code wouldn’t render):

[?php if(is_single()) { ?]
[li class="sidebox"]
[?php get_author_profile(); ?]
[h2]Author Info:[/h2]
[ul]
[li][?php author_profile(); ?][/li]
[li][?php author_profile('profile'); ?][/li]
[/ul]
[/li]
[?php } ?]

Saman Sadeghi
Comment » January 11, 2007 @ 3:13 pm

Here is little better description of the problem:

I would like to display the author’s profile in the sidebar on that author’s posts only. So, if the current post is written by author “Steve” who’s id = 4, then post his profile in the sidebar.

The problem I am having is how to read the author’s ID - without having the pass it manually. WordPress would need to find the author’s ID of the current post and display the correct profile – I need this because there are multiple authors and I want that author’s info on their posts.

Dan
Comment » January 16, 2007 @ 4:06 pm

there seems to be a problem with the new wordpress version (security update 2.07)… i disabled the plugin and now nothing… any idea?

Bradley Charbonneau
Comment » January 30, 2007 @ 3:59 am

Wow, I’m almost there! Thanks for your plugin, it’s fantastic. I’m trying to get even more data from users because I’ve set up the “userextra” (usermeta) plugin (http://dev.wp-plugins.org/wiki/Userextra). I’m not a programmer by any means, but I was hoping something like, instead of “$user->icq” I could use “$userextra->address_street” for example (having already set up a field called Street Address (address_street). Do you think this could work?

OK, it’s late, I’m tired, but I wanted to ask. Thanks for all of your plugins. I’ve been using WP for a few years now and I remember your site from a few years ago thanks to your The Excerpt Reloaded plugin. Thanks–and best regards, — Bradley

Bradley Charbonneau
Comment » January 30, 2007 @ 3:57 pm

Got it! I knew it would be one of those late-night expeditions into the depths of forums and files! Thanks to your file and this forum post, I got it working! I can now pull any custom field I want into a viewable list! Thank you for the file and your work here. Best, Bradley

David
Comment » March 22, 2007 @ 4:17 am

Hi Kaf, sounds like a great plugin. Had some hassle with plugins the past week, causing real havoc in the WP database. So if you don’t mind me asking: has anyone tested ‘get author profile’ with WP2.1?
Thanks

Vladimir
Comment » March 26, 2007 @ 2:58 pm

404 author page solution:
function wp_404_author_error_filter_posts_where(&$where) {
if((0 == count($wp_query->posts)) && (is_author() || is_category())) {
global $wp;
$wp->did_permalink=false; // Allows zero results without -> 404
}
return $where;
}
add_filter(‘posts_where’, ‘wp_404_author_error_filter_posts_where’,11);

Kitty
Comment » April 20, 2007 @ 9:23 am

Could someone spell this out for those of us who are not as WordPress savvy? I’ve installed the usermeta and userextra and I just want to know how to make the fields display on the author pages. If someone could just give me a simple step by step or even just copy and paste their code with “PUT YOUR FIELD NAME” here and so on that would be fabulous.

Markus
Comment » April 23, 2007 @ 6:43 am

Thanks for the great Plugin an the page-Template. It works fine! I like to add the function (show the local user-avatar) form the identitikit-plugin (http://www.john-noone.com/2007/03/14/le-bout-du-tunnel/). Can you help me – i try a lot of thinks but it doesnt work.

Thank you for your time and work!
Greetings.
Markus

Steve
Comment » April 27, 2007 @ 10:08 am

The page-authors-2.0.php sounds like exactly the thing I’ve been looking on. Only, I have no idea how to use it. I uploaded into my theme folder, but it doesn’t show as an available template (just default, links and archives). What am I missing here? Thanks!

Steve
Comment » April 27, 2007 @ 11:39 am

Ahh, I got it. It just wanted the template tag closed off.

Any suggestions on how I can get it to change the layout? I’d like them to show maybe three across before going down to the next line. That would make the layout a little neater.

Phil
Comment » May 1, 2007 @ 6:40 pm

Hi, sorry to bother. I’m finding the explanation of how to actually use the All Authors Template extremely confusing/illusive. I just want to be able to click a link and have this page open, and display a list of authors with other bits of information. I’ve read all of the above comments, as well as the link you provided to the Wordpres Codex. I can see from the code of this page that this is exactly what this page is supposed to do, however I have no idea how to execute it. If I link to the file directly, I just get about a thousand php errors. I already have the ability to view a single authors profile, i just want this to loop for all the authors (who arent admin). Please help before my mind implodes.

http://www.holmbushrecords.com/test.html

This is the site im working on (for a uni project due very soon), the “artists” link is what i want this script for.

WordPress version 2.0

Thankyou

Kahil
Comment » May 18, 2007 @ 12:53 am

I too am having trouble with this. I can get this plugin to work by setting it to a specific user, but I can’t figure out how to make it so that it will show the name based on whether or not someone is logged in or not. For example, if I am logged in and I go to my site, it’ll show my name. If you are logged in it will show your name and info. But if you visit and aren’t logged in, then it would show no info… I have tried everything I can find and nothing works, I even made an author.php page…

Thanks in advance

Fatherdom
Comment » June 6, 2007 @ 1:54 am

What is going on with your plugins? Why are there break tags in front of everything? It is great that you write good plugins, but copying the damn code line by line sucks!!!!!!!!!! ^M
^M
^M
Source for page-authors-2.0.php^M
^M
^M
^M

@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ "page-authors-2.0.php" 13L, 32013C 1,1 Top

Henrique
Comment » July 20, 2007 @ 4:51 pm

Hello Kaf, evendough I couldn’t make it work, thanks already for your pluggin.

I tried to install it in my multiple User blog, powered by wordpress 2.2

I use CMD avatar pluggin for showing the pictures of the Authors in every post.

I want the user to be able to see the profile of every author by clicking on it’s name on the post footer (or on the avatar picture – but if this is more complicated I would be more than satisfied with the first option.

This is what I tried…..

I put your get_author_profile() tag inside The Post DIV in my Idex.php:

[?php if (have_posts()) : ?][?php while (have_posts()) : the_post(); ?]
[div class="post"]
[h2][a href="[?php the_permalink() ?]” rel=”bookmark” title=”[?php the_title(); ?]“][?php the_title(); ?][/a][/h2]

[div class="contenttext"]
[?php the_content('Read more »'); ?]
[p class="postinfo"][?php if(function_exists('cmd_show_avatar')){ cmd_show_avatar(); } ?][strong]Posted by: [/strong][a href="get_author_profile()"][?php the_author_firstname()?][/a][strong] On: [/strong][?php the_time('F jS, Y') ?][br /] under [?php the_category(', ') ?].[br /]
[?php akst_share_link(); ?] | [a href="[?php comments_link(); ?]“][strong]Comments:[/strong] [?php comments_number('none','1','%'); ?][/a]
[?php edit_post_link('Edit this post',' | ',''); ?][/p]
[/div]

when someone clicks on the Post author name link, the browser searches for: http://www.lets-evo.net/skateboard/get_author_profile()

the browser sends the person who clicked to this page which I made a screenshot: http://www.lets-evo.net/get_author_pluggin_error.jpg

I have created a author.php that looks like the following and i have put it inside my theme’s folder.Maybe it should be somewhereelse

[?php
/*
Template Name: Author profile
*/
?]

[?php get_header(); ?]

[div id="contentwide"]

[?php if (have_posts()) : while (have_posts()) : the_post(); ?]

[?php list_subpages_andreas01(); ?] [?php // This generates the subpage menu. If you don't want to use it, delete this line. ?]

[div class="post"]

[h2][?php the_title(); ?][/h2]

[?php the_content('[p class="serif"]Read more »[/p]‘); ?]

[?php link_pages('[p][strong]Pages:[/strong] ‘, ‘[/p]‘, ‘number’); ?]

[?php get_author_profile(); ?]
[div class="profile"]
[ul]
[li id="myprofile"]Blog Owner:
[ul]
[li][?php author_profile('firstname'); ?] [?php author_profile('lastname'); ?][/li]
[li]Jabber: [?php author_profile('jabber'); ?][/li]
[li]AIM: [?php author_profile('aim'); ?][/li]
[li]Notes: [?php author_profile('profile'); ?][/li]
[/ul]
[/li]
[/ul]
[/div]

[?php edit_post_link('Edit this page','[p]‘,’[/p]‘); ?]

[?php endwhile; endif; ?]

[/div]

[/div]

[?php get_footer(); ?]


I would really apreciate if you could give me some of your advice on getting it right

Henrique
Comment » July 21, 2007 @ 5:55 pm

…Just one thing…I sad that my site is Multiple user blog, but it is not a MU WordPress…It is just a normal blog where I set up more than one Author.

Doug
Comment » September 15, 2007 @ 5:27 pm

Ok, I’m trying to set this up on my blog because it appears from the description to be what I need. The problem is that I don’t see any instructions for use anywhere in this post. How do I make this plugin work?

Phil
Comment » September 20, 2007 @ 8:30 am

Is there any way of getting the date the user joined from this? I’ve tried adding it in to the plugin myself with no success :(

philipp
Comment » October 6, 2007 @ 7:54 pm

Exactly what I was looking for… Thanks for this plugin – works perfect!

deep.thought
Comment » October 8, 2007 @ 4:23 am

Hello all,

Does anyone know how to display a profile for a user that hasn’t posted? I have it all working very nicely for a user that has posted. They get a pretty url like /author/site_user/ however if they haven’t posted their is no link (just their name) and I have to manually access their profile using /?author=ID any help would be much appreciated.

Regards.

Holger
Comment » October 30, 2007 @ 2:30 am

For a very long time, I was looking for exact this information.
Thank you for this plugin…..

Kind regards
Holger.

Chet
Comment » December 28, 2007 @ 6:24 pm

How can I have a user update their profile within my sites template, rather then having it go through the WordPress Template?

Chet

Richard
Comment » December 29, 2007 @ 4:20 pm

This is probably the dumbest question you have ever had.

How do I save the file? I have two authors and want seperate pages for them. I am a newbie.

Also I am using wordpress 2.31

Alex
Comment » January 16, 2008 @ 3:23 pm

Just dropping by to say thanks :) just what i needed.

Video izlesene
Comment » May 15, 2008 @ 11:59 am

Thank you for this plugin bot WP2.5.1???

kaspelon
Comment » May 16, 2008 @ 3:39 pm

Can i get the comment author login name?

Scott Hendison
Comment » August 31, 2008 @ 8:53 am

I’ve been using this plug-in for a long time on multiple blogs and love it, but do have one question…

Occasionally an author will make his file very long, and while standard HTML seems to work for links, I can’t for the life of me figure out how to force linebreaks.

I found a reference on Lorelles blog claiming this –
>>>
Make sure the line breaks are single space and the paragraphs have two spaces. To “force” a line break you can use but only in that format
>>>

But that doesn’t seem to do it either. Do you have any idea how to force a manual line break in the author bio?

Rose
Comment » September 16, 2008 @ 4:21 pm

I have this same problem! Have searched the web for plugins or anything to make it possible to have paragraphs or at least line-breaks in the profile text on the author page, but I can’t get it to work. Why doesn’t it just support html :(
That claim you wrote doesn’t work for me either.

Sorry I’m of no help, but if anyone else knows anything.. paragraphs in author profiles in wordpress…
It would be really helpful!

Adam Austin
Comment » September 24, 2008 @ 6:56 am

@Rose & Scott Hendison
I have also been searching for a solution to include page breaks into author bio text, I managed a basic way of doing this using php’s ‘str_replace’ function: (Scott, your post about two spaces helped me to figure this…)

In your author bio, include two spaces where you want the page break to occur, then replace <?php echo $curauth->description; ?> with <?php echo str_replace(‘ ‘,”, $curauth->description); ?> – make sure to include two spaces in the first parameter of str_replace.

This will replace any two spaces in your author bio with a line break. (change ” to ” if you would rather use paragraph tags). You could also use this technique for including other basic formatting, such as or tags, just choose a unique symbol or html entity in your bio text, then use str_replace to change that symbol into the html tag of your choice.

Hope this helps!

David
Comment » October 17, 2008 @ 10:05 pm

Rose and Scott: Weasel’s HTML Bios Plugin will allow you to put line breaks or whatever other HTML you want to use in your user profiles.

Everyone: Just tested Get Author Profile on WP 2.5.1, works great.

Kenley Neufeld
Comment » November 22, 2008 @ 8:27 pm

Thanks for all the help here. I have successfully created a list of authors in my sidebar with links to their respective author pages. They all work correctly, except for the user who is admin. The admin does appear in the list of authors, but when I follow the link, I get a ‘Error 404 – Not Found’. I know I’ve included the admin because the name is in the list of authors with a link, just nothing on the subsequent page.

Any clues?

levani
Comment » January 2, 2009 @ 4:36 am

How can I write post author ID outside the loop on wordpress 2.7?

Rose
Comment » January 12, 2009 @ 2:46 pm

Oh! Thank you guys!!!!! David & Kenley!
Going to try this out :)

Amir
Comment » February 11, 2009 @ 12:46 am

Does this work for WP 2.7?

Amir
Comment » February 11, 2009 @ 8:48 am

Works with WP 2.7.1

Just checked.

aristid
Comment » February 18, 2009 @ 3:44 pm

hi

i want to do the following: if the page title IS found as username THEN get AuthorID and set it to $id.

i’m very new to php and until now i’m not able to manage it.

tia

ari

Sky
Comment » February 21, 2009 @ 1:47 pm

will that work in WordPress 2.7?

venz
Comment » April 10, 2009 @ 12:13 am

following up on Saman Sadeghi’s question:

in a single page view, how do we get the author ID of the author of the current post in a dynamic way?

basically what brought me here was that i wanted to display author profile information in a single page outside of the loop.

Aaron Clausen
Comment » May 30, 2009 @ 7:32 am

Exactly, I need to do this to.

Why can’t we “Get Author ID of the author of the current post” outside of THE LOOP?

Mister Payne
Comment » July 5, 2009 @ 5:43 pm

how do i get the current author, especially on a single post page, instead of specifying a particular author?

Konisto
Comment » August 23, 2009 @ 8:52 pm

Hi,

I’m looking for something that would allow me to show a limited (10 or so) random author avatars of my multi author blog in my side bar widget. Is this possible with your plugin and how?

Thanks!

Phil

eddihughes
Comment » October 27, 2009 @ 6:19 pm

yeah i dont understand why wordpress doesn’t have this already, im going to throw myself off a bridge

Willy
Comment » November 26, 2009 @ 1:54 am

Here is the method that allows you getting the author ID of the current post outside the loop.

http://www.dbuggr.com/milly/obtain-author-id-author-profile-wordpress-loop/

meghmala
Comment » December 9, 2010 @ 1:38 am

This does not work on wordpress 3.2 .what can i do?
please give suggeation.

Gwen
Comment » April 25, 2011 @ 12:39 am

We do a bunch of articles from different authors and I’,m wanting only certain authors to come up on specific pages. I stumbled upon this attempting to refine my author content based on conditional terms? Is this now redundant given the new plug ins for wordpress? Or should I be pursing this?

Thanks for the guidance, would appreciate some direction either way.

Gwen
http://waterfiltersystem.co/Water Filter Systems Victoria BC Canada

alexander fap turbo james
Comment » June 6, 2011 @ 4:33 pm

Gwen,

I did a quick search on http://wordpress.org/extend/plugins/search.php?q=get+author+profile&sort= and it did not bring up any info on this Get Author Profile plugin.

What’s more the plugins on that page are mostly outdated and haven’t been updated since 2008 – 2009. With the current version of WordPress being 3.1.3 you may not need a plugin to handle author bio displays. Even if you do you would want something built and updated to the latest version of wordpress. Hope that helps.

 

* Required field (e-mail is not published). Breaks and paragraphs are automatic. HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>