Skip to content

Commit

Permalink
e107inc#4991: Fix improper array access in sc_signup_extended_user_fi…
Browse files Browse the repository at this point in the history
…elds

Fixes: e107inc#4991
  • Loading branch information
Deltik committed Apr 16, 2023
1 parent c351764 commit 1e601fb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion e107_core/shortcodes/batch/signup_shortcodes.php
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,7 @@ function sc_signup_extended_user_fields($parm = null)
{
$opts = $parm;
$required = (int) $ext['user_extended_struct_required'];
$edit = isset($_POST['ue']['user_' . $ext['user_extended_struct_name']]) ? $_POST['ue']['user_' . $ext['user_extended_struct_name']] : '';

if($required === 0) // "No - Will not show on Signup page".
{
Expand All @@ -545,7 +546,7 @@ function sc_signup_extended_user_fields($parm = null)
$replace = array(
$label,
($required === 1 ? $this->sc_signup_is_mandatory('true') : ''),
$ue->renderElement($ext, varset($_POST['ue']['user_' . $ext['user_extended_struct_name']]), $opts)
$ue->renderElement($ext, $edit, $opts)
);

$text .= str_replace($search, $replace, $this->template['extended-user-fields']);
Expand Down

0 comments on commit 1e601fb

Please sign in to comment.