Mega Code Archive

 
Categories / Php / Class
 

Defining three member functions for Cat

<?php Class Cat {   // Constructor   function __constructor(  ) {   }   // The cat meows   function meow(  ) {     echo "Meow...";   }   // The cat eats   function eat(  ) {     echo "*eats*";   }   // The cat purrs   function purr(  ) {     echo "*Purr...*";   } } ?>