Setting a default timezone?


Posted on 16th Feb 2014 07:03 pm by admin

I have read about how to change the timezone in PHPMYADMIN, but it changes back, it doesn't STAY there.
If thats not possible, if I had..;
$time = date("d-m-Y H-i-s" time());
or.. if I had
$time = time();

I think I am 6 hours ahead PHPMYADMIN time.
To set it in php.. would it be..


$t = 6 * 3600; // 3600 seconds in an hour, times it by 6. This could be 5 though.
$time = date("d-m-Y H:i:s" time()) + $t; // For the current date

// Or like..
$t = 6 * 3600; // 3600 seconds in an hour, times it by 6. This could be 5 though.
$time = time() + $t; // For the currunt unix timestamp


Also, how would I change the PHPMYADMIN default timestamp.. so that when I enter the dates, it'll show up with .. the correct time for GMT-london.

Thanks

No comments posted yet

Your Answer:

Login to answer
102 Like 44 Dislike
Previous forums Next forums
Other forums

Weekly Calendar
Hi, I am looking at creating a weekly calendar. The calendar will read from Monday - Sunday. Does an

remove a ; from emails in textarea
Code: <?php

session_start();

$database_host = "localhost&qu

simple ping code
been searchin the site/web and found code thats simple but doesnt work.

I have a personal we

I apologise! It's a newbie to PHP feedback form problem!
Hi,

I am a total newbie to PHP. I am also a unemployed and need to get a job. So after 100% r

Open link with largest int string first
I have the following links i would like to open either all at once or one-by-one. How would i procee

Retrieving innerHTML with cURL?
Hey all (sorry I know I'm a leecher, but I soon won't be. This is my first PHP project, but not my l

date("now") prints out wrong date ?
Hi Guys
Anyone know why and how I can fix it ?

parse error
On my local machine I keep getting parse error for my footer. When I put it online, it doesn't show

Need help making login verification cleaner...
I use the below to verify user login. I first check the cookie for the id, ip and a unique id. If it

split string
Hi all

i have some names (imploded by comma):
Code: toronto,paris,madrid
Now, i would

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash