-
What shortcode you tried to produce this bug? And did you use it on author template?
Yes only on author.php using [userpro template=view max_width=95% user=author] sorry this was happening before you made the change forgot to mention it but I thought it had to do with the 0 post issue
Ah so the change fixed the profiles/cards on author archive but this issue stayed from beginning?
Ok, which permalink setting are you using in userpro?
I used
add_filter(‘userpro_user_profile_url’, ‘userpro_author_url’, 99, 2);
function userpro_author_url($link, $user_id) {
return get_author_posts_url( $user_id );
}this what my theme link is to the author.php <?php echo get_author_posts_url($current_user->ID);?>”>
Ahmed is there a way to make this not change the followers and following links?
add_filter(‘userpro_user_profile_url’, ‘userpro_author_url’, 99, 2);
function userpro_author_url($link, $user_id) {
return get_author_posts_url( $user_id );
}In your functions/api.php
Change this
$link = apply_filters(‘userpro_user_profile_url’, $link, $user_id);
to:
if ($request == ‘profile’ || $request == ‘view’) {
$link = apply_filters(‘userpro_user_profile_url’, $link, $user_id);
}This will affect only profile permalinks and keep login, register, other pages un-affected.
Try it and let me know
Works great. This is a subtle but very significant feature to USERPRO. We are now totally free to create amazing profiles pages which are connected to the wordpress author archive.
Is there away to change mysite.com/?author=1 to mysite.com/username
You must be logged in to reply to this topic.