Time and date

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

Xerpher
New php-forum User
New php-forum User
Posts: 164
Joined: Tue Aug 27, 2002 8:25 pm
Location: Ontario, Canada
Contact:

Time and date

Postby Xerpher » Mon Oct 07, 2002 4:43 pm

I couldn't figure this out from php.net so I came to the next best place :D

I've got the date function working the way I want it to date("m/d/y"), but I want to get the time in that same basic format ( like 8:43:28 { HH:MM:SS } )

Anyone know what I have to do?

DoppyNL

Postby DoppyNL » Mon Oct 07, 2002 10:44 pm

just use the date function, it can also handle times! it is described in the manual: http://www.php.net/date

you could also use strftime optionally in combination with setlocale, that way you can create dates in a lot of languages :)

Greetz Daan

Xerpher
New php-forum User
New php-forum User
Posts: 164
Joined: Tue Aug 27, 2002 8:25 pm
Location: Ontario, Canada
Contact:

Postby Xerpher » Tue Oct 08, 2002 7:30 am

:oops: I didn't notice all those extra commands I could put in the date string. Thanks :D


Return to “PHP coding => General”

Who is online

Users browsing this forum: No registered users and 1 guest

cron