Welcome Guest, Not a member yet? Register   Sign In
How to set right TimeZone in .env
#1

I try to add TimeZone in .env but still don't have effect:
app.appTimezone = 'Europe/Rome'
  • I find in file app/Config/App.php "public $appTimezone = 'America/Chicago';  and if change to Europe/Rome still don't have effect.
Reply
#2

It seems you are doing right.

I see Europe/Rome.

Code:
--- a/app/Config/App.php
+++ b/app/Config/App.php
@@ -109,7 +109,7 @@ class App extends BaseConfig
      *
      * @var string
      */
-    public $appTimezone = 'America/Chicago';
+    public $appTimezone = 'Europe/Rome';

    /**
      * --------------------------------------------------------------------------
diff --git a/app/Controllers/Home.php b/app/Controllers/Home.php
index 7f867e95f..46e182792 100644
--- a/app/Controllers/Home.php
+++ b/app/Controllers/Home.php
@@ -6,6 +6,6 @@ class Home extends BaseController
{
    public function index()
    {
-        return view('welcome_message');
+        return app_timezone();
    }
}
Reply
#3

Thanks, fixed. Problem is in SQLite module.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB