Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

To find out the current year is leap year or not which
date() function we've to use.Give the syntax also

Answer Posted / vaneet badhan

to check the current year code is :

date("L");
output will be 1 coz 2008 is a leap year.

better way to check is :

$year=2008;
echo date("L",mktime(1,1,1,1,1,$year));
now you can check any year by just changing the value of
variable $year, this is called dynamic programming.

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What software is required for php?

983


Why shouldn't I use mysql_* functions in php?

1005


What are php string functions?

933


How can we submit a form without using submit buttons?

915


What is http php?

895


What is session cookies php?

921


What is difference between readonly and constant?

939


What is basename php?

899


Why delimiter is used in mysql?

1008


What is difference between include,require,include_once and require_once()?

992


Explain the difference between urlencode and urldecode?

993


How can image properties be retrieved in php?

931


Why is php used for web development?

915


What websites use php?

917


How to enable error reporting in php?

998