Re: [PHP] Need help with timestamp....

2001-07-05 Thread Brian White

As I understand it,
* "strftime" takes a format string and an integer timestamp and returns a 
date string
* "date" takes a different type of format string and an integer timestamp 
and returns a date string

In both cases they default to using the timestamp for the current time.

SO: what you code is doing is
1) Calculating a date string using "date" based on the current time
2) Passing that string to strfttime at a point where it is expecting an integer
timestamp, and that is being interpreted as 0 or -1 ( not sure which )

Maybe just:

define('SUB_BAR_TITLE', strftime(DATE_FORMAT_LONG));


At 20:46 5/07/2001 -0400, JustinS wrote:
>I want to stamp the CURRENT time on my page...
>
>as of right now it's reading
>
>==
>
>Wednesday 31 December, 1969
>
>==
>
>i assume im not doing something correctly...
>
>the following is how i have the line written atm
>
>define('SUB_BAR_TITLE', strftime(DATE_FORMAT_LONG, (date ("F d, Y h:i:s 
>A";
>
>no, i did not write this script, which is the reason i dunno what the heck 
>im doing -- im curious if anyone has some insight on the problem
>
>Thanks in advance.
>

-
Brian White
Step Two Designs Pty Ltd - SGML, XML & HTML Consultancy
Phone: +612-93197901
Web:   http://www.steptwo.com.au/
Email: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Need help with timestamp....

2001-07-05 Thread Jay Paulson

if you want the current time all you have to do is this.. :)

echo date("l d F, Y g:i A")

that will out put:

Thursday 05 July, 2001 7:52 PM

or whatever time your system is at it will echo it in that format.. hope
that helps!

jay

- Original Message -
From: "JustinS" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, July 05, 2001 7:46 PM
Subject: [PHP] Need help with timestamp


I want to stamp the CURRENT time on my page...

as of right now it's reading

==

Wednesday 31 December, 1969

==

i assume im not doing something correctly...

the following is how i have the line written atm

define('SUB_BAR_TITLE', strftime(DATE_FORMAT_LONG, (date ("F d, Y h:i:s
A";

no, i did not write this script, which is the reason i dunno what the heck
im doing -- im curious if anyone has some insight on the problem

Thanks in advance.





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Need help with timestamp....

2001-07-05 Thread JustinS

I want to stamp the CURRENT time on my page...

as of right now it's reading

==

Wednesday 31 December, 1969

==

i assume im not doing something correctly...

the following is how i have the line written atm

define('SUB_BAR_TITLE', strftime(DATE_FORMAT_LONG, (date ("F d, Y h:i:s A";

no, i did not write this script, which is the reason i dunno what the heck im doing -- 
im curious if anyone has some insight on the problem

Thanks in advance.