One User Profile for the whole site.
Date: Monday, August 16 @ 05:27:45 CEST Topic: PHP-Nuke
Tired of seeing 2 profiles of ONE user of your website? Forums profile edit is not what you want your users to use? Tired of seeing 2 links to edit/register at your website? (one Forums and one in Your Account)
Well I have made some changes to eliminate one profile/registeration system/profile edit system from your PHP-Nuke powered websites.
Read more to find out how...
2 files needed to be edit.
includes/page_header.php
modules/Forums/profile.php
1: Open includes/page_header.php and look for these 2 lines (Around line 400 and 401):
'U_REGISTER' => append_sid('profile.'.$phpEx.'?mode=register'),
'U_PROFILE' => append_sid('profile.'.$phpEx.'?mode=editprofile'),
And change them to:
'U_REGISTER' => append_sid('modules.php?name=Your_Account&op=new_user'),
'U_PROFILE' => append_sid('modules.php?name=Your_Account&op=edituser'),
2: Open modules/Forums/profile.php (around line 92), look for this code:
if ( $mode == 'viewprofile' )
{
include("includes/usercp_viewprofile.php");
exit;
}
Change it to:
if ( $mode == 'viewprofile' )
{
$profiledata = get_userdata(intval($HTTP_GET_VARS[POST_USERS_URL]));
header("Location: modules.php?name=Your_Account&op=userinfo=$profiledata[username]");
exit;
}
That's it!
You can see it working at Nuke Gangsta
|
|