To find out the current year is leap year or not which
date() function we've to use.Give the syntax also
Answer Posted / mahesh
$dt = getdate();
$year = $dt['year'];
$month =
$array(1=>31,(($dt['year']-2000)%4?28:29),31,30,31,30,31,31,30,31,30,31);
if array[2]==29
then it is a leap year.
Otherwise Not
| Is This Answer Correct ? | 0 Yes | 5 No |
Post New Answer View All Answers
When is a conditional statement ended with endif?
What is whitespace in html?
How to get the value of current session id?
What is the difference between associative array and indexed array?
Tell me what is the main difference between php 4 and php 5?
What is trim codeigniter?
What is php default argument?
Tell me can you extend a final defined class?
Who is known as the father of php?
Why post method is used in php?
how to open & closing opening period in fico
Declare a new variable in php equal to the number 3;
How does one prevent the following warning ‘warning: cannot modify header information – headers already sent' and why does it occur in the first place?
What is php simple definition?
How are php sessions stored?