Skip to Content

Ezeelogin GUI web interface is showing a different time than the system time.

Ezeelogin GUI web interface is showing a different time than the system time.

 

There will be a difference in the time shown in GUI and the system.  If we have not set it manually the time will be the default time, as shown in the following screenshots.
 
 
 
 
root@gateway:~# date
Tue May 11 12:00:17 IST 2021
 
When we access the php.info page it shows the default timezone as UTC.
 
1. Add the PHP info page using the following steps;
 
root@gateway:~# vi $(awk '/^www_folder/ {print $2}' /usr/local/etc/ezlogin/ez.conf)info.php
<?php phpinfo(); ?>
 
 
 
2. To set both GUI time and server time same, change the timezone in the /etc/php.ini file ;
 
root@gateway:~# vi /etc/php.ini
 
Uncomment the date. timezone function and set its value to the timezone you need.
 
 
 
To see a list of supported timezones, refer to php.net.  
 
3. After editing the file, restart the httpd service.
 
 root@gateway:~#systemctl restart httpd
 
4. After restarting the service, compare the GUI time with the server time.
 
 
 
root@gateway:~# date
Tue May 11 12:00:24 IST 2021
 
Access the license tab and also the server time, thus the correct time would be displayed. Also on the PHP page, the time zone has changed to the time zone we have set.
 
 
5. If there still exists a time difference in the GUI and server, create a PHP page and add the following. 
 
root@gateway:~#vi $(awk '/^www_folder/ {print $2}' /usr/local/etc/ezlogin/ez.conf)time.php
<?php
echo "The time is " . date("h:i:sa");
?>
 
In order to test that our system is configured properly for time, compare the server time with the time showing in the  time.php page. 
 
The following image shows an example for time.php in the browser.