MySql time problem

Discussion in 'Databases' started by dizyn, Feb 11, 2010.

  1. #1
    Hi,

    I am using a shared hosting which has EST US time, since i am on shared hosting that's why i cannot change the server time zone but i wanted to display local Pakistan time to my users. For example a user lists an item he/she wants to see at what time item was listed and they wanted to see it in Pakistan time not EST US time.

    What's the best solution to do this? Wanted to do it on database level..

    Thanks
    -Mannan
     
    dizyn, Feb 11, 2010 IP
  2. jestep

    jestep Prominent Member

    Messages:
    3,659
    Likes Received:
    215
    Best Answers:
    19
    Trophy Points:
    330
    #2
    If this is a php server, you can put something like this in .htaccess. PHP does need to be running as an apache module for this to work.

    php_value date.timezone "Asia/Karachi"

    I just guessed on the timezone. Here's the list of ones in Asia: http://www.php.net/manual/en/timezones.asia.php
     
    jestep, Feb 11, 2010 IP
  3. chengary

    chengary Banned

    Messages:
    88
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #3
    Change the system time zone.
     
    chengary, Feb 19, 2010 IP