RE: [PHP] OOP, Classes, Sharing Code
| From: | Jay Blanchard | Date: | Mon, 28 Jun 2004 18:41:19 +0000 |
| Subject: | RE: [PHP] OOP, Classes, Sharing Code | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-189171@lists.php.net to get a copy of this message | ||
[snip]
So my question is, should I just duplicate the code in each class
(Portfolio and Album), or is there a better way of organizing all of
this?
[/snip]
If you are going to duplicate code why not just create a generic class
with the code that would be duplicated and then extend the class as
required?