Question[Help] Get Time and Date

Posts 1–3 of 3 · Page 1 of 1
[Help] Get Time and Date
I'm working on making some contact forms for a non-profit. Well I tested it and it works but it doesn't send the Time and date. This is what I have:

Code:
<form method="post" action="Contact-Send.php">

<?php
$time = getenv("F d, Y  :  g:i:s A");
?>

<input type="hidden" name="time" value="<?php echo $time ?>" />
Then the rest of the form, the action page is fine I checked it. I just need to know what I did wrong to make it not post the time and date.


+Rep +1 Thanks


Thanks for the help.
PHP (like w3) has a great way to answer all of your questions.

PHP: Hypertext Preprocessor

$today = getdate();

Why are you using getenv? It's used to return the value of a environment variable. I know enough PHP to get by, but it isn't one of my languages. Let me know.
Okay thanks, and because the tutorial I found for it told me to do it that way....lol


I'll test this one out later, Thanks.
Posts 1–3 of 3 · Page 1 of 1

Post a Reply

Tags for this Thread

None

Talk with us