Correct time...
Moderator: General Moderators
Correct time...
My site is hosted on a server in canada or something, and the time in Norway (where I live) is 2 hours ahead of the time in Canada! So how can i get the server to display the correct time, when the format is like this:
$time = date ("H:i:s");
$time = date ("H:i:s");
-
daemorhedron
- Forum Commoner
- Posts: 52
- Joined: Tue Jul 23, 2002 11:03 am
localtime() user contributed notes
to set up berlin time it could look like this:
<?php
print "<HTML><body><pre>";
setlocale( "LC_ALL", "de_DE" );
putenv( "PHP_TZ=Europe/Berlin" );
$now = time();
print_r( localtime(time(),true) );
print_r( getdate() );
print date("H:i:s");
print date("T");
?>
gosh, I like the online manualFabian.Rodriguez@toxik.com
14-Dec-2000 07:19
Language information is defined by this RFC:
RFC1766 - Tags for the Identification of Languages
- http://www.ietf.org/rfc/rfc1766.txt
And the 2 letter codes come from:
ISO639: "Code for the representation of names of languages"
- http://www.w3.org/WAI/ER/IG/ert/iso639.htm
ISO3166-1: "English country names and code elements"
- http://www.din.de/gremien/nas/nabd/iso3 ... index.html
Also note that the language name can be used in full (ex: setlocale('LC_TIME','swedish'); ) . This full name comes from the latest mentioned file.