/    Sign up×
Community /Pin to ProfileBookmark

Please help with getting Time/Date on a page

Here is what I am trying to do!

Today is Fri, November 3, 2006

The time is 12:45:16 PM

Not sure how to get the string for Today is and The time is. This is what have now.

Any info would be much appreciated!!

Here is the code that I have and now I can’t get the date to show:

<html>
<head>
<title>Date/Time site</title>
</head>
<body>

<?php
print date(“l, F d, Y.h:iA” ,time ());
?>
</body>
</html>

to post a comment
PHP

1 Comments(s)

Copy linkTweet thisAlerts:
@so_is_thisNov 03.2006 — Does this work for you?
<i>
</i>Today is &lt;?=date('D, F j, Y')?&gt;

The time is &lt;?=date('g:i:s A')?&gt;
×

Success!

Help @duff2481 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.27,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...