Notifications
Clear all

wpForo 1.x.x How to redirect users profiles links to my own users profiles pages ?

6 Posts
2 Users
0 Likes
2,132 Views
Posts: 3
Topic starter
(@geve2009)
Active Member
Joined: 5 years ago

Hi,

I've seen somewhere that it could not be possible, but my website (intras.fr) already get hundred of profiles pages, well referenced. I just have created some forums using the (very good) WPForo plugin, but it creates many new profiles pages.

My profiles pages are custom one and I don't want to change them !

Is it possible to create something like "add action" with some function ?

Thanks for your answer and sorry for any mistakes, my native language is french.

5 Replies
Robert
Posts: 9988
Admin
(@robert)
Support Team
Joined: 7 years ago

Hi @geve2009,

Yes that's possible. Please leave your website URL and some example of the profile pages.

Reply
Posts: 3
Topic starter
(@geve2009)
Active Member
Joined: 5 years ago

Hi,

website url with your forum : https://www.intras.fr/forum/forum-formation/

Examples of profile page :

https://www.intras.fr/formateurs/fiche-membre/?ID=37

and

https://www.intras.fr/freelances/profil-freelance/?ID=463

 

This is depending on user's role.

Thanks for any help 🙂

Reply
Robert
Posts: 9988
Admin
(@robert)
Support Team
Joined: 7 years ago

You should only change the profile page, but leave the Account, Subscription and Activity Menus. They are forum specific pages and your forum users will not be able to change account information in forum.

To replace profile URLs to your custom profile URLs put this code in your active WordPress theme functions.php file:

function change_wpforo_profile_to_custom_url( $url = '', $member = array(), $template = 'profile' ){
if( wpfval($member, 'ID') ){
return get_option('siteurl') . '/formateurs/fiche-membre/?ID=' . $member['ID'];
}
return $url;
}
add_filter( 'wpforo_member_profile_url', 'change_wpforo_profile_to_custom_url', 10, 3 );

How to Easily Add Custom Code in WordPress (without Breaking Your Site)

Reply
1 Reply
(@geve2009)
Joined: 5 years ago

Active Member
Posts: 3

Thousand thanks for this fast an nice answer. It works well and I had customized it for my own use.

Suggestion : Why don't add this in your next update ?
A backoffice screen which Offer options to select the profile link (UM profile, WC profile, ... and custom profile).

It would be very usefull for anyone.

 😀  Of course, I went to submit a 5 stars review for your nice plugin, but...

I would be happy to get ALL my WPForo screens translated into french language...
I had completed the PO file for french translation, but it seems that some words aren't into the translation file (i.e. "Unread posts" as link at the bottom of a forum, and some others... Thanks to check.

Reply
Robert
Posts: 9988
Admin
(@robert)
Support Team
Joined: 7 years ago

Also I recommend disable wpForo Profile Page indexing in Dashboard > Forums > Settings > Features admin page:

Reply