Anonymous user / 3.145.85.233 Log In Register
?
Wallet: 3.00
Daily Credits:
1.20 / 1.20

PHP Functions Online


getdate

(PHP 4, PHP 5)

getdateGet date/time information

array getdate([int $timestamp = time()])

Checkout ? #

Item Description Item Price Your Price
Total

Preview #

${{ variable.param.name }} = {{ variable.param|getValue:variable.form:true }};
{{ call.result}} = ;

Description #

array getdate ([ int $timestamp = time() ] )

Returns an associative array containing the date information of the timestamp, or the current local time if no timestamp is given.

Parameters #

timestamp

The optional timestamp parameter is an integer Unix timestamp that defaults to the current local time if a timestamp is not given. In other words, it defaults to the value of time().

Return Values #

Returns an associative array of information related to the timestamp. Elements from the returned associative array are as follows:

Examples #

Example #1 getdate() example

<?php
$today 
getdate();
print_r($today);
?>

The above example will output something similar to:

Array
(
    [seconds] => 40
    [minutes] => 58
    [hours]   => 21
    [mday]    => 17
    [wday]    => 2
    [mon]     => 6
    [year]    => 2003
    [yday]    => 167
    [weekday] => Tuesday
    [month]   => June
    [0]       => 1055901520
)

See Also #