PHP Classes

PHP Dog Age Calculator: Convert the age of a dog a person equivalent

Recommend this page to a friend!
  Info   View files Example   View files View files (2)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 76 This week: 1All time: 10,145 This week: 560Up
Version License PHP version Categories
ab_ 1.0Freeware5PHP 5, Time and Date, Biology
Description 

Author

This class can convert the age of a dog a person equivalent.

It can take the number of years of age of a dog and converts it to the equivalent in years of age of a human.

The class returns an array that has the number of dog years of age and a text message with a cumpliment or a recommendation to take care of your dog.

In Spanish:

Convierte la edad de un perro a edad humana. Esta simple clase convierte la edad de un perro a edad humana segun el promedio de vida de ambos y ademas retorna un mensaje según la edad calculada.

Picture of Dannel
  Performance   Level  
Name: Dannel <contact>
Classes: 9 packages by
Country: Cuba Cuba
Age: 30
All time rank: 30438 in Cuba Cuba
Week rank: 411 Up1 in Cuba Cuba Up
Innovation award
Innovation award
Nominee: 5x

Example

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>
  <title>My Dog | Human Age</title>
</head>

<body>

<?php
require("dogage.php");
if(isset(
$_POST['age'])){
$obj=new dogHumanAge;

$age=$obj->dogAge($_POST['age']);
echo
'Your Dog is <b><font color="#FF0000">'.$age['humanizedAge'].'</font></b> years old in human age.<br />';
echo
$age['message'];
}else{
?>
<form method="POST">
Please input your dog&apos;s age:<br />
<input type="number" name="age" />
<input type="submit" value="OK"/>
</form>


<?php } ?>
</body>

</html>


  Files folder image Files  
File Role Description
Plain text file dogage.php Class Class
Accessible without login Plain text file example.php Example Example script

 Version Control Unique User Downloads Download Rankings  
 0%
Total:76
This week:1
All time:10,145
This week:560Up