.oO(forums.macromedia.com)
>I have a query that is pulling info from a mySQL database
and is updating a
>page on a daily basis. The info in the database is
pre-loaded. I have set my
>timezone on the server so if I login via putty and type
in "date", I see the
>correct date/time stamp for my timezone but the time is
still GMT.
I'm not sure I understand: It shows the correct time for your
time zone,
but a 'GMT' after it even if it should be something else?
>However, when my page queries the database, it's still
grabbing info from
>GMT. Obviously, I was mistaken that setting this timezone
setting would
>influence the webpage query.
It should. By default MySQL will take the TZ setting from the
machine it
runs on, unless you configure it to something else.
>(and my query is going basically like:
>SELECT *
>FROM tableName
>WHERE MONTH(fieldname) = MONTH(CURRENT_DATE) AND
YEAR(fieldname) =
>YEAR(CURRENT_DATE) AND fieldname <= CURRENT_DATE()
There's also a timezone setting in recent PHP versions, which
should be
set if you work with PHP's date and time functions:
date_default_timezone_set()
http://www.php.net/date_default_timezone_set
Micha