Jump to content


Photo

timezone web server?


  • Please log in to reply
3 replies to this topic

#1 Wiranata

Wiranata

    Newbie

  • New Members
  • Pip
  • 8 posts

Posted 16 January 2013 - 06:56 PM

how to configuration time zone in mysql web server??
i have web server idhostinger

#2 trq

trq

    Advanced Member

  • Administrators
  • 30,995 posts
  • LocationSydney, Australia.

Posted 16 January 2013 - 08:45 PM

Your going to need to clarify your issue. Mysql is a *database* server.

http://thorpesystems.com | http://proemframework.org | http://github.com/trq

SmtpCatcher - A very simple mock sendmail useful for testing PHP mail scripts.
OPM - My Linux package manager.


#3 Wiranata

Wiranata

    Newbie

  • New Members
  • Pip
  • 8 posts

Posted 17 January 2013 - 05:38 AM

Your going to need to clarify your issue. Mysql is a *database* server.

Your going to need to clarify your issue. Mysql is a *database* server.


how can i do this??
in localhost i succesfully about this,but when i upload form with timezone...timezone is wrong

#4 jazzman1

jazzman1

    Advanced Member

  • Gurus
  • 2,611 posts
  • LocationMississauga, Canada

Posted 19 January 2013 - 10:26 AM

When MySQL has been started, by default it takes the time zone of the local machine(server).

If you are using shared hosting server, you don't have permissions to change a global time zone on the server and the database.

By default each client that connects has its own time zone setting, given by the session time_zone variable in MySQL.

You can change your own time_zone using the sql SET statement.

For example:


SET time_zone = 'America/Toronto'

or

SET time_zone = '+07:00'

or

ALTER DATABASE <database_name> SET time_zone = 'America/Toronto'


Take a look at here to obtain much more details about this.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Cheap Linux VPS from $5
SSD Storage, 30 day Guarantee
1 TB of BW, 100% Network Uptime

AlphaBit.com