1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-01 20:30:39 +02:00

Merge pull request #1935 from MikeyGMT/mikey20161017

Fixes #1887 User Setting Fix for Users with No Userclass plus some Notice Removals
This commit is contained in:
Cameron
2016-10-17 10:05:11 -07:00
committed by GitHub
5 changed files with 17 additions and 17 deletions

View File

@@ -198,7 +198,7 @@ class usersettings_shortcodes extends e_shortcode
$inclass = implode(',',$is_checked);
// $ret = "<table style='width:95%;margin-left:0px'><tr><td class='defaulttext'>";
$ret .= $e_userclass->vetted_tree('class',array($e_userclass,checkbox_desc),$inclass,'editable, no-excludes');
$ret .= $e_userclass->vetted_tree('class',array($e_userclass,'checkbox_desc'),$inclass,'editable, no-excludes');
// $ret .= "</td></tr></table>\n";
return $ret;
@@ -473,7 +473,7 @@ class usersettings_shortcodes extends e_shortcode
$parms = explode("^,^",$fInfo['user_extended_struct_parms']);
$fhide="";
if($parms[3])
if(varset($parms[3]))
{
$chk = (strpos($this->var['user_hidden_fields'], "^user_".$parm."^") === FALSE) ? FALSE : TRUE;
if(isset($_POST['updatesettings']))

View File

@@ -46,7 +46,7 @@ $sc_style['PASSWORD_LEN']['pre'] = "<br /><span class='smalltext'> (".LAN_USE
$sc_style['PASSWORD_LEN']['post'] = " ".LAN_USER_79.")</span>";
$sc_style['USERCLASSES']['pre'] = "<tr>
<td style='width:40%;vertical-align:top' class='forumheader3'>".LAN_USER_76.":".req($pref['signup_option_class'])."
<td style='width:40%;vertical-align:top' class='forumheader3'>".LAN_USER_76.":".req(varset($pref['signup_option_class']))."
<br /><span class='smalltext'>".LAN_USER_73."</span>
</td>
<td style='width:60%' class='forumheader2'>";
@@ -77,7 +77,7 @@ $sc_style['LOGINNAME']['pre'] = "<tr>
$sc_style['LOGINNAME']['post'] = "</td></tr>\n";
$sc_style['SIGNATURE']['pre'] = "<tr><td style='width:40%;vertical-align:top' class='forumheader3'>".LAN_USER_71.req($pref['signup_option_signature'])."</td>
$sc_style['SIGNATURE']['pre'] = "<tr><td style='width:40%;vertical-align:top' class='forumheader3'>".LAN_USER_71.req(varset($pref['signup_option_signature']))."</td>
<td style='width:60%' class='forumheader2'>";
//$sc_style['SIGNATURE']['pre'] = "<tr><td style='width:40%;vertical-align:top' class='forumheader3'></td>
@@ -125,14 +125,14 @@ $USERSETTINGS_EDIT = "
{LOGINNAME}
<tr>
<td style='width:40%' class='forumheader3'>".LAN_USER_60.req(!$pref['disable_emailcheck'])."</td>
<td style='width:40%' class='forumheader3'>".LAN_USER_60.req(!varset($pref['disable_emailcheck']))."</td>
<td style='width:60%' class='forumheader2'>
{EMAIL}
</td>
</tr>
<tr>
<td style='width:40%' class='forumheader3'>".LAN_USER_63.req($pref['signup_option_realname'])."</td>
<td style='width:40%' class='forumheader3'>".LAN_USER_63.req(varset($pref['signup_option_realname']))."</td>
<td style='width:60%' class='forumheader2'>
{REALNAME}
</td>
@@ -154,7 +154,7 @@ $USERSETTINGS_EDIT = "
</tr>
<tr>
<td style='width:40%; vertical-align:top' class='forumheader3'>".LAN_USER_07.req($pref['signup_option_image'])."</td>
<td style='width:40%; vertical-align:top' class='forumheader3'>".LAN_USER_07.req(varset($pref['signup_option_image']))."</td>
<td style='width:60%' class='forumheader2'>
{AVATAR_REMOTE}
</td>
@@ -214,7 +214,7 @@ $USERSETTINGS_WRAPPER['edit']['CUSTOMTITLE'] = "<div class='form-group'>
";
$USERSETTINGS_WRAPPER['edit']['USERCLASSES'] = "<div class='form-group'>
<label class='col-sm-3 control-label'>".LAN_USER_76.":".req($pref['signup_option_class'])."</label>
<label class='col-sm-3 control-label'>".LAN_USER_76.":".req(varset($pref['signup_option_class']))."</label>
<div class='col-sm-9'>{---}</div>
</div>
";
@@ -233,7 +233,7 @@ $USERSETTINGS_WRAPPER['edit']['PHOTO_UPLOAD'] = "<div class='form-group'>
$USERSETTINGS_WRAPPER['edit']['SIGNATURE'] = "<div class='form-group'>
<label for='signature' class='col-sm-3 control-label'>".LAN_USER_71.req($pref['signup_option_signature'])."</label>
<label for='signature' class='col-sm-3 control-label'>".LAN_USER_71.req(varset($pref['signup_option_signature']))."</label>
<div class='col-sm-9'>{---}</div>
</div>
";
@@ -256,14 +256,14 @@ $USERSETTINGS_TEMPLATE['edit'] = "
<div class='form-group'>
<label for='email' class='col-sm-3 control-label'>".LAN_USER_60.req(!$pref['disable_emailcheck'])."</label>
<label for='email' class='col-sm-3 control-label'>".LAN_USER_60.req(!varset($pref['disable_emailcheck']))."</label>
<div class='col-sm-9'>
{EMAIL}
</div>
</div>
<div class='form-group'>
<label for='realname' class='col-sm-3 control-label'>".LAN_USER_63.req($pref['signup_option_realname'])."</label>
<label for='realname' class='col-sm-3 control-label'>".LAN_USER_63.req(varset($pref['signup_option_realname']))."</label>
<div class='col-sm-9'>
{REALNAME}
</div>
@@ -284,7 +284,7 @@ $USERSETTINGS_TEMPLATE['edit'] = "
</div>
<div class='form-group'>
<label class='col-sm-3 control-label'>".LAN_USER_07.req($pref['signup_option_image'])."</label>
<label class='col-sm-3 control-label'>".LAN_USER_07.req(varset($pref['signup_option_image']))."</label>
<div class='col-sm-9'>
{AVATAR_REMOTE}
</div>
@@ -320,4 +320,4 @@ $USERSETTINGS_TEMPLATE['extended-field'] = "<div class='form-group'>
?>
?>

View File

@@ -726,8 +726,8 @@ class e107_user_extended
$parms = explode("^,^",$struct['user_extended_struct_parms']);
$include = preg_replace("/\n/", " ", $tp->toHtml($parms[0]));
$regex = $tp->toText($parms[1]);
$regexfail = $tp->toText($parms[2]);
$regex = $tp->toText(varset($parms[1]));
$regexfail = $tp->toText(varset($parms[2]));
$fname = "ue[user_".$struct['user_extended_struct_name']."]";
$required = vartrue($struct['user_extended_struct_required']) == 1 ? "required" : "";
$fid = $frm->name2id($fname);

View File

@@ -731,7 +731,7 @@ class UserHandler
}
else
{
if ($userData['user_class'] != '') $classList = explode(',',$userData['user_class']);
if (!empty($userData['user_class'])) $classList = explode(',',$userData['user_class']);
}
foreach (array(e_UC_MEMBER, e_UC_READONLY, e_UC_PUBLIC) as $c)
{

View File

@@ -178,7 +178,7 @@ if (isset($_POST['updatesettings']))
}
// Uploaded avatar and/or photo
if ($file_userfile['error'] != 4)
if (varset($file_userfile['error']) != 4)
{
require_once (e_HANDLER.'upload_handler.php');
require_once (e_HANDLER.'resize_handler.php');