Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
122 views
in Q2A Core by
Describe please...!

2 Answers

+5 votes
by

1) open qa-config.php

2) at very bottom write below code with your region.

date_default_timezone_set('Asia/Ashgabat');

+2 votes
by

If you're managing your own server you can set the timezone in php.ini by assigning the proper timezone to the date.timezone setting, e.g.:

date.timezone = "Asia/Dubai"

Restart the PHP service afterwards to have it pick up the change.

Alternatively you can set the system timezone on the server (although I'd recommend sticking to the php.ini approach). How you change the system timezone depends on your operating system. On Linux you set/change the symlink /etc/localtime to the desired timezone, e.g.:

ln -sf /usr/share/zoneinfo/Asia/Dubai /etc/localtime

On Windows you change the timezone in the date & time settings.

Again, restart the PHP service to make it pick up the change.


If you don't have admin access to the system you need to set the timezone by adding a line

date_default_timezone_set('Asia/Dubai');

to your qa-config.php as @esqeudero described in his answer.

by
I added a line in qa-config.php
But it is not working..
by
Define "not working." Are you getting errors in your webserver logs? If so, what do they say? Also, please show the change you made (copy/paste the added line and a couple lines before and after that into your question).
by
I think it worked. Thanks again
...