mirror of
https://github.com/e107inc/e107.git
synced 2025-08-04 13:47:31 +02:00
menumanager_class.php: fixed path for menu config action (it included '.php' and leaded to '.php.php' anding);
signup.php: added default empty values for user_class, user_perms, user_prefs, user_realm as they were leading to DB Insert error;
This commit is contained in:
@@ -1060,7 +1060,7 @@ class e_menuManager {
|
|||||||
$conf = '';
|
$conf = '';
|
||||||
if (file_exists(e_PLUGIN.$menu_path.$menu_name.'_menu_config.php'))
|
if (file_exists(e_PLUGIN.$menu_path.$menu_name.'_menu_config.php'))
|
||||||
{
|
{
|
||||||
$conf = $menu_path.$menu_name.'_menu_config.php';
|
$conf = $menu_path.$menu_name.'_menu_config';
|
||||||
}
|
}
|
||||||
|
|
||||||
if($conf == '' && file_exists(e_PLUGIN."{$menu_path}config.php"))
|
if($conf == '' && file_exists(e_PLUGIN."{$menu_path}config.php"))
|
||||||
@@ -1187,7 +1187,6 @@ class e_menuManager {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function menuSetConfigList()
|
function menuSetConfigList()
|
||||||
{
|
{
|
||||||
global $sql,$pref;
|
global $sql,$pref;
|
||||||
@@ -1226,13 +1225,5 @@ class e_menuManager {
|
|||||||
|
|
||||||
$pref['menuconfig_list'] = $tmp;
|
$pref['menuconfig_list'] = $tmp;
|
||||||
save_prefs();
|
save_prefs();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
} // end of Class.
|
} // end of Class.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
?>
|
|
10
signup.php
10
signup.php
@@ -513,7 +513,8 @@ if (isset($_POST['register']))
|
|||||||
}
|
}
|
||||||
// Work out data to be written to user audit trail
|
// Work out data to be written to user audit trail
|
||||||
$signup_data = array('user_name', 'user_loginname', 'user_email', 'user_ip');
|
$signup_data = array('user_name', 'user_loginname', 'user_email', 'user_ip');
|
||||||
foreach (array() as $f)
|
// foreach (array() as $f)
|
||||||
|
foreach ($signup_data as $f)
|
||||||
{
|
{
|
||||||
$signup_data[$f] = $allData['data'][$f]; // Just copy across selected fields
|
$signup_data[$f] = $allData['data'][$f]; // Just copy across selected fields
|
||||||
}
|
}
|
||||||
@@ -526,6 +527,13 @@ if (isset($_POST['register']))
|
|||||||
|
|
||||||
$allData['data']['user_join'] = time();
|
$allData['data']['user_join'] = time();
|
||||||
|
|
||||||
|
// The user_class, user_perms, user_prefs, user_realm fields don't have default value,
|
||||||
|
// so we put apropriate ones, otherwise - broken DB Insert
|
||||||
|
$allData['data']['user_class'] = '';
|
||||||
|
$allData['data']['user_perms'] = '';
|
||||||
|
$allData['data']['user_prefs'] = '';
|
||||||
|
$allData['data']['user_realm'] = '';
|
||||||
|
|
||||||
// Actually write data to DB
|
// Actually write data to DB
|
||||||
validatorClass::addFieldTypes($userMethods->userVettingInfo,$allData);
|
validatorClass::addFieldTypes($userMethods->userVettingInfo,$allData);
|
||||||
$nid = $sql->db_Insert('user', $allData);
|
$nid = $sql->db_Insert('user', $allData);
|
||||||
|
Reference in New Issue
Block a user