Bug #23278 Bug Fixed

When changing localization settings from forum cp, undefined index error is thrown.

Version: 4.0.4 Reporter: Bill the Grue

Hello all!

When changing localization settings on forum undefined index error is thrown. All other changes seem to work as expected.

To reproduce:

  1. spin up a clean 3.5.12 instance with forum addon.
  2. as a logged in member, from the following URI: MYSITE.FOO/forums/member/edit_localization
  3. try to make any changes and save.

The error is below:


Undefined index: site_default

ee/EllisLab/Addons/member/mod.member_settings.php, line 1643 hide details

Severity: E_NOTICE

the code block at line 1643:

foreach (array('timezone', 'date_format', 'time_format', 'include_seconts') as $key)
                        if ($_POST['site_default'] == 'y')
                                $data[$key] = NULL;
                                $data[$key] = ee()->input->post($key);

Robin note: Setting the seconds and the ‘use default’ aren’t sticking in my v4 tests. Not sure why the radio wouldn’t be set, but it makes sense to check for it in any case.

  • I tested on v4 and I’m confirming there’s some bugyness on the forum localization settings. We’ll get that fixed up for v4 and I’ve put a short term patch up in the solution tab that will eliminate the php error for now.

    Thanks for the report!

    Robin Sowell
    28th December, 2017 at 6:36pm

You must be signed in to comment on a bug report.

  • ee/EllisLab/Addons/member/mod.member_settings.php around line 1643

    if ($_POST['site_default'] == 'y')
    change to
     if (isset($_POST['site_default']) && $_POST['site_default'] == 'y')
.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases