Page 1 of 2

phpBB URL For User Profile www.domain.com/User Name

Posted: 05 Dec 2012, 21:54
by Blue Blood
URL For User Profile http://www.domain.com/User Name
This will allow the user profile link to be the users name

Code: Select all

http://www.projectblueblood.com/memberlist.php?mode=viewprofile&u=2
Will now be

Code: Select all

http://www.projectblueblood.com/Blue Blood
Open
.htaccess

At the end of the file add

Code: Select all

RewriteEngine on
Rewriterule ^([^/\.]{3,})$ ./memberlist.php?mode=viewprofile&un=$1
Open
includes/functions_content.php

Find:

Code: Select all

$profile_url = ($custom_profile_url !== false) ? $custom_profile_url . '&u=' . (int) $user_id : str_replace(array('={USER_ID}', '=%7BUSER_ID%7D'), '=' . (int) $user_id, $_profile_cache['base_url']);
After Add

Code: Select all

$profile_url = generate_board_url() . '/' . $username;

phpBB URL For User Profile www.domain.com/User Name

Posted: 05 Dec 2012, 22:26
by Stoker
Open
includes/functions_content.php
Find does not exist.

phpBB URL For User Profile www.domain.com/User Name

Posted: 05 Dec 2012, 22:47
by martin123456
Closest i can find is

Code: Select all

$profile_url = ($custom_profile_url !== false) ? $custom_profile_url . '&u=' . (int) $user_id : str_replace(array('={USER_ID}', '=%7BUSER_ID%7D'), '=' . (int) $user_id, $_profile_cache['base_url']);

phpBB URL For User Profile www.domain.com/User Name

Posted: 06 Dec 2012, 00:29
by Blue Blood
martin123456 wrote:Closest i can find is

Code: Select all

$profile_url = ($custom_profile_url !== false) ? $custom_profile_url . '&u=' . (int) $user_id : str_replace(array('={USER_ID}', '=%7BUSER_ID%7D'), '=' . (int) $user_id, $_profile_cache['base_url']);
This is it...

The edits were for phpBB 3.0.8

I updated the edit!!

phpBB URL For User Profile www.domain.com/User Name

Posted: 06 Dec 2012, 00:44
by martin123456
Confirmed and works nice edit blueblood
2012-12-05_224504.png

phpBB URL For User Profile www.domain.com/User Name

Posted: 06 Dec 2012, 01:01
by Solidjeuh
Nice! Now I can use short link to profiles in Prochatrooms!
Thank you :D

phpBB URL For User Profile www.domain.com/User Name

Posted: 07 Dec 2012, 15:05
by Solidjeuh
This is also replacing the url in the Arcade mod
So we cannot click on a user to see his game statistics..
it leads directly to their profile..
Anyway ti fix this please?

http://phpbbarcade.jatek-vilag.com/viewtopic.php?p=4

phpBB URL For User Profile www.domain.com/User Name

Posted: 07 Dec 2012, 22:56
by Blue Blood
Solidjeuh wrote:This is also replacing the url in the Arcade mod
So we cannot click on a user to see his game statistics..
it leads directly to their profile..
Anyway ti fix this please?

http://phpbbarcade.jatek-vilag.com/viewtopic.php?p=4
I will check it out tonight!!

EDIT:

See if this works


Replace this

Code: Select all

$profile_url = generate_board_url() . '/' . $username;
With this

Code: Select all

$profile_url = append_sid($phpbb_root_path . $username);
Its really should be

Code: Select all

append_sid
instead of

Code: Select all

generate_board_url
this could possibly log users out any way

This probably wont fix the problem but this code is better then the original line.

I will have to look at the Arcade code...

phpBB URL For User Profile www.domain.com/User Name

Posted: 09 Dec 2012, 04:24
by Solidjeuh
No this changes nothing .. still the same problem :)

phpBB URL For User Profile www.domain.com/User Name

Posted: 09 Dec 2012, 12:16
by Blackwolf
I tried it & got my default self modified 404 page..... :|