PHP Classes
Icontem

File: LeapYearChecker_example.php


  Search   All class groups All class groups   Latest entries Latest entries   Top 10 charts Top 10 charts   Newsletter Newsletter   Blog Blog   Forums Forums   Help FAQ Help FAQ  
  Login   Register  
Recommend this page to a friend! ReTweet ReTweet Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Ellery Leung  >  Leap year checker  >  LeapYearChecker_example.php  
File: LeapYearChecker_example.php
Role: Example script
Content type: text/plain
Description: Leap Year Checker example
Class: Leap year checker
Check whether a given year is a leap year
 

Contents

Class file image Download
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=big5">
<title>Leap Year Checker</title>
</head>

<body>
<?php
include("LeapYearChecker.class.php");
$LYC = new LeapYearChecker();
$LYC->isLeapYear(1999) == true ? print "Is leap year." : print "Not leap year";
print 
"<br/>";
$LYC->isLeapYear(2000) == true ? print "Is leap year." : print "Not leap year";
print 
"<br/>";
$LYC->isLeapYear(2006) == true ? print "Is leap year." : print "Not leap year";
?>
</body>
</html>

 
  Advertise on this site Advertise on this site   Site map Site map   Statistics Statistics   Site tips Site tips   Privacy policy Privacy policy   Contact Contact  

For more information send a message to :
info at phpclasses dot org.
Copyright (c) Icontem 1999-2009 PHP Classes - PHP Class Scripts
  PHP Book Reviews - Reviews of books and other products