Echo author ID in author.php

This is probably a super simple question. But how do I echo the ID of a user on author.php? I’ve tried the_author_meta(‘ID’) But it didn’t seem to want to work. I want to echo it at the end of a URL, for example; http:///www.domain.com/author/sampleauthor-id Obviously, where “id” is that particular author’s ID Any ideas? 3 … Read more

Change the Author Slug from Username to Nickname

Hi to the community, is it possible to change the default username slug to nickname if is available? By default the url is something like: http://domain.tld/author/(admin) , is it possible to rewrite and change to http://domain.tld/author/(nickname) so if a user change his nickname from the profile page the slug it will change also to the … Read more

How to get a buddypress user profile link and a certain user profile field for the current post author?

I want to replace get_author_link() and get_the_author_meta($feld) with something equivalent to point to the author of the current post Buddypress user profile page and retrieve a specific profile field from his Buddypress page ie, I just want to show a link to the post user profile and a biography from one of his BP profile … Read more

How to remove the author pages?

I submitted my site to Google and now the author page is showing up in the search results. http://www.domain.com/author/myusername How do I prevent my and others author names from showing up in search results? It would be best to disable completely the path “/author/” all together because it’s not a blog but a product site … Read more

How to get Author ID outside the loop

I can’t get the post author ID outside the loop to make the get_the_author_meta work. So far I’ve tried different approaches: 1. $author_id=$post->post_author; 2. global $post; $author_id=$post->post_author; 3. $post_tmp = get_post($post_id); $author_id = $post_tmp->post_author; 4. $author_id = $posts[0]->post_author; I need the author ID to pass it on to: $address = get_the_author_meta(‘user_email’, $author_id); Any suggestions? 8 … Read more

get post author id outside loop

I need to place in post edit dashboard metabox with post author e-mail (or other user meta fields). So it can be edited when admin reviews this post. $meta_id = get_the_author_meta( ‘user_email’, $user_id ); $meta_box = array( ‘id’ => ‘my-meta-box’, ‘title’ => ‘DANE FIRMY’, ‘page’ => ‘post’, ‘context’ => ‘normal’, ‘priority’ => ‘high’, ‘fields’ => … Read more

How to check if a user (not current user) is logged in?

I need to display the online status (online/offline) for each author page (custom author page template). is_user_logged_in() only applies to the current user and I can’t find a relevant approach targeting the current author e.g. is_author_logged_in() Any ideas? One Trick Pony was kind enough to prepare the coding for two to three functions using transients, … Read more