mirror of
https://github.com/e107inc/e107.git
synced 2025-08-02 20:57:26 +02:00
Disable login.php when a custom e_LOGIN is used. (customlogin.php for example)
This commit is contained in:
@@ -2358,7 +2358,11 @@ class e107
|
|||||||
|
|
||||||
// login/signup
|
// login/signup
|
||||||
define('e_SIGNUP', SITEURL.(file_exists(e_BASE.'customsignup.php') ? 'customsignup.php' : 'signup.php'));
|
define('e_SIGNUP', SITEURL.(file_exists(e_BASE.'customsignup.php') ? 'customsignup.php' : 'signup.php'));
|
||||||
define('e_LOGIN', SITEURL.(file_exists(e_BASE.'customlogin.php') ? 'customlogin.php' : 'login.php'));
|
|
||||||
|
if(!defined('e_LOGIN'))
|
||||||
|
{
|
||||||
|
define('e_LOGIN', SITEURL.(file_exists(e_BASE.'customlogin.php') ? 'customlogin.php' : 'login.php'));
|
||||||
|
}
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
@@ -20,7 +20,7 @@
|
|||||||
require_once("class2.php");
|
require_once("class2.php");
|
||||||
include_lan(e_LANGUAGEDIR.e_LANGUAGE.'/lan_'.e_PAGE);
|
include_lan(e_LANGUAGEDIR.e_LANGUAGE.'/lan_'.e_PAGE);
|
||||||
|
|
||||||
if (USER)
|
if (USER || e_LOGIN !='login.php') // Disable page if user logged in, or some custom e_LOGIN value is used.
|
||||||
{
|
{
|
||||||
header('location:'.e_BASE.'index.php');
|
header('location:'.e_BASE.'index.php');
|
||||||
exit();
|
exit();
|
||||||
|
Reference in New Issue
Block a user