how many ways we get current date in php
Answers were Sorted based on User's Feedback
Answer / swapna
$date_time = date('Y-m-d H:i:s'); use this one you can get
current date.
Is This Answer Correct ? | 88 Yes | 28 No |
Answer / mahesh
$date = getdate()
Here $date prints as an Array.with current date and Time
Is This Answer Correct ? | 24 Yes | 25 No |
Answer / tasimkhan
$date = date('d-M-Y H:i:s', strtotime(time(0))
Is This Answer Correct ? | 4 Yes | 7 No |
What is array and function?
What is php and its features?
What is php.ini & .htacess file?
What is php and sql used for?
Differentiate between php5 and php7?
What is php namespace?
How to protect special characters in query string?
how retrive the video file in php using video tag
What is curl php?
iam mca post graduate in 2010 not getting job in JAVA so iam looking for carear in php as market demand is high so it is best option to try for php or not
How can we destroy the cookie?
What is the meaning of curl , which is used while connecting with pay pal? and how it works?