Home :: International :: Manuals :: Howto :: FAQ :: Man Pages :: Email Login

 
 

 

localtime

(PHP 4 , PHP 5)

localtime -- ローカルタイムを得る

説明

array localtime ( [int timestamp [, bool is_associative]])

localtime()関数は同名のC言語の関数コールにより 返される構造体と同じ内容の配列を返します。 localtime()の最初の引数はtimestampであり、 省略された場合には現在の時間が使用されます。 localtime()の2番目の引数は is_associativeであり、これが0に設定されるか 指定が省略された場合には、配列は通常の数値を添字とした配列として 返されます。その引数が1に設定された場合、 localtime()はC言語の関数localtimeのコール により返される構造体の全ての要素を有する連想配列を返します。 この連想配列の各キーの名前は次のようになります。

  • "tm_sec" - 秒

  • "tm_min" - 分

  • "tm_hour" - 時間

  • "tm_mday" - 月単位の日付

  • "tm_mon" - 月

  • "tm_year" - 年、1900年からの年

  • "tm_wday" - 週単位の日付

  • "tm_yday" - 年単位の日付

  • "tm_isdst" - 夏時間が有効かどうか

 
 
 
 
Google
  Web Linuxinfor   
 

Home :: Copyright :: Privacy :: Credits :: Get a free Linuxinfor Email Account

Document on this page is part of "PHP マニュアル". See Index Page for more info about Authorship and Copyright.

1999-2009 Linuxinfor.com. No rights reserved.