We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

BUG in the CI Date helper timezone_menu or upgrade glitch?

Development and Programming

Paul Sijpkes's avatar
Paul Sijpkes
13 posts
12 years ago
Paul Sijpkes's avatar Paul Sijpkes

I’ve updated the title for this since I’ve made some progress, see my follow on post for details about a possible bug in CI.

I’m getting this error after upgrading to 2.6.1. I missed the clear cache step on upgrade, could this have affected this?

Severity: Notice
Message: Undefined index: Australia/Sydney
Filename: libraries/Localize.php
Line Number: 735

—- UPDATE —

It’s actually the Session class which is returning Australia/Sydney instead of the PHP timezone code (‘UP10’), Localize tries to use this as an index, obviously causing an error.

       
Paul Sijpkes's avatar
Paul Sijpkes
13 posts
12 years ago
Paul Sijpkes's avatar Paul Sijpkes

Okay, I’ve narrowed it down to the mod.member_settings.php file in the Member theme:

The mod.member_settings module generates the localization page for the user using the Localize class in the edit_localization() function.

The Localize class uses the CI Date helper timezone_menu() function to generate a localization menu, but this provides the string ‘Sydney/Australia’ in the <option> tag, which means this is what is passed back to the update_localization() function in mod.member_settings.php.

See line 1593 in mod.member_settings.php:

$data['timezone'] = $_POST['server_timezone'];

Now, it seems that there a bug in the javascript generated by timezone_menu(), because surely the <option> tag should be generated with the time zone codes (i.e. <option value=’UP10’>Sydney</option>?

Anyone have any ideas?

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.