Bug #4648 [NEW]: DB_DataObject docs: bug in one of the examples

From: Date: Tue, 21 Jun 2005 14:12:47 +0000
Subject: Bug #4648 [NEW]: DB_DataObject docs: bug in one of the examples
Groups: php.pear.doc 
Request: Send a blank email to pear-doc+get-6379@lists.php.net to get a copy of this message
From: lists at norbert dot mocsnik dot hu Operating system: irrelevant PHP version: Irrelevant Package: Documentation Bug Type: Bug Bug description: DB_DataObject docs: bug in one of the examples Description: ------------ db-dataobject/intro-purpose.xml line 112: function getAge() { $age = date('Y') - date('Y',$this->birthDate); } The evaluated expression should be returned instead of putting it into a local variable. here is the corrected version: function getAge() { return date('Y') - date('Y',$this->birthDate); } -- Edit bug report at http://pear.php.net/bugs/bug.php?id=4648&edit=1 --

« previous php.pear.doc (#6379) next »