Fix Module ‘timezonedb’ already loaded

When I was upgrading my apps to Codeigniter 3, I got an error message on my development server.

A PHP Error was encountered

Severity: Core Warning

Message: Module ‘timezonedb’ already loaded

Filename: Unknown

Line Number: 0

Backtrace:

Actually, it wasn’t Codeigniter error. It was the server. It seems the server duplicated loading timezonedb module. I searched on google and never got satisfaction answer. The worst is many people suggest by hidden its error message.

Luckily, I used Cpanel to manage my server and I found Cpanel forum old thread, it said to edit my php.ini if you use latest Cpanel version, you will find that it has multi-PHP version. So you should check php.ini for the PHP version you used for application. Since, mine was 5.6 so I edited this file

/opt/cpanel/ea-php56/root/etc/php.ini

then search and comment out this line

; date.timezone = “UTC”

remember this “;” is comment mark for php.ini.

Leave a Comment

Your email address will not be published. Required fields are marked *