On Tue, 26 Jun 2001 00:28, Tyler Longren wrote:
> Hello,
>
> I have something like this:
> $Month = "6";
> $Year = "2001";
> $Date = "1";
>
> Is there any relatively simple way to get the day out of that? For
> example, the day for 6-1-2001 would be Friday.
>
> Thanks,
> Tyler
If that info comes
date('l', mktime(0,0,0, $Month, $Day, $Year));
- Original Message -
From: "Tyler Longren" <[EMAIL PROTECTED]>
To: "php-general" <[EMAIL PROTECTED]>
Sent: 2001. jĂșnius 25. 16:58
Subject: [PHP] date -> day
> Hello,
>
> I have something like this:
> $Month = "6";
> $Year = "2001";
> $Dat
Use mktime() and then date().
http://www.php.net/manual/en/function.mktime.php
http://www.php.net/manual/en/function.date.php
- Tim
http://www.phptemplates.org
- Original Message -
From: "Tyler Longren" <[EMAIL PROTECTED]>
To: "php-general" <[EMAIL PROTECTED]>
Sent: Monday, June 25, 2
mktime can be pretty useful :
$year = 2001;
$month = 6;
$day = 1;
print date('l',mktime(0,0,0,$month,$day,$year));
as it creates a unix timestamp, and date() appreciates that.
Regards,
Philip
On Mon, 25 Jun 2001, Tyler Longren wrote:
> Hello,
>
> I have something like this:
>
4 matches
Mail list logo