squishi
06-09-2009, 10:54 AM
I would like to directly link to the standard error page (where the user is redirected when they don't have the necessary permissions).
It's not possible to link to it directly.
But maybe it would be possible to create a small plugin that triggers the permission error when you link to - say - "login.php?do=somegetcode" ?
--------------- Added 1244549416 at 1244549416 ---------------
Okay. I had to change the login.php file to do this.
Unfortunately, there were not enough hooks in that file.
By changing this
else if ($_GET['do'] == 'login')
{
// add consistency with previous behavior
exec_header_redirect($vbulletin->options['forumhome'] . '.php');
}
to this
else if ($_GET['do'] == 'login')
{
print_no_permission();
}
I am now able to link to a separate login page.
--------------- Added 1244549514 at 1244549514 ---------------
Could the hook "login_redirect" be used to do this?
It's not possible to link to it directly.
But maybe it would be possible to create a small plugin that triggers the permission error when you link to - say - "login.php?do=somegetcode" ?
--------------- Added 1244549416 at 1244549416 ---------------
Okay. I had to change the login.php file to do this.
Unfortunately, there were not enough hooks in that file.
By changing this
else if ($_GET['do'] == 'login')
{
// add consistency with previous behavior
exec_header_redirect($vbulletin->options['forumhome'] . '.php');
}
to this
else if ($_GET['do'] == 'login')
{
print_no_permission();
}
I am now able to link to a separate login page.
--------------- Added 1244549514 at 1244549514 ---------------
Could the hook "login_redirect" be used to do this?