News:

Wondering if this will always be free?  See why free is better.

Main Menu

Profile as default login page

Started by falguni1, November 21, 2007, 02:00:45 AM

Previous topic - Next topic

falguni1

the default page after we login is the homepage

how do I make the profile the default page after we login in

Dragooon

In /Sources/LogInOut.php(FIRST MAKE A BACKUP AS I HAVE NOT TESTED IT!)
Find
// Double check the cookie...
elseif (isset($_GET['sa']) && $_GET['sa'] == 'check')
{
// Strike!  You're outta there!
if ($_GET['member'] != $ID_MEMBER)
fatal_lang_error('login_cookie_error', false);

// Some whitelisting for login_url...
if (empty($_SESSION['login_url']))
redirectexit();
else
{
// Best not to clutter the session data too much...
$temp = $_SESSION['login_url'];
unset($_SESSION['login_url']);

redirectexit($temp);
}
}

replace with
// Double check the cookie...
elseif (isset($_GET['sa']) && $_GET['sa'] == 'check')
{
// Strike!  You're outta there!
if ($_GET['member'] != $ID_MEMBER)
fatal_lang_error('login_cookie_error', false);

// Some whitelisting for login_url...
if (empty($_SESSION['login_url']))
redirectexit($scripturl . '?action=profile');
else
{
// Best not to clutter the session data too much...
$temp = $_SESSION['login_url'];
unset($_SESSION['login_url']);

redirectexit($temp);
}
}

Make sure to BACKUP the file before doing this. This is 100% untested.

- danny

i like this idea. if anyone tests it, please post results.

Bulakbol

Please do not PM me for support · My Mods and Theme · SMF Coding Guidelines · Modifications Approval Guidelines

- danny

sweet. i tested it and have it in use on 1.1.4. :) thanks!

brianjw

I think that would annoy users sometimes but that's my opinion...
However, is it possible to make something for the first time they login to the forum ever, it directs them to their profile and only that one time...

brianjw

djrem


nay27uk

Quote from: brianjw on December 12, 2007, 04:48:38 PM
I think that would annoy users sometimes but that's my opinion...
However, is it possible to make something for the first time they login to the forum ever, it directs them to their profile and only that one time...

brianjw

Yeah i agree If this was made so when people join they was redirected to fill in their profile then that's cool. maybe someone could do this for us

brianjw


Adish - (F.L.A.M.E.R)


brianjw

The difference is, is that the mod I posted only transfers to profile once and that is right after you register. It doesn't continue when you login. ;)

Advertisement: