![]() |
learning OOP in PHP
Hi,
This post is not meant to flame OOP'ers. I'm trying to learn OOP (PHP4), but I'm having a hard time getting why OOP is more reusable than my procedual functions. I use a "functions.php" file where I have stashed all my functions, connect to db, resize an image... and so on. How would i write the following code using OOP, and make it more reusable? |
Re: learning OOP in PHP
All Database related to one class, image related in other class. mail related in other ... This way you can use some of the existing classes to gain more stability.
|
Re: learning OOP in PHP
Thanks
|
Re: learning OOP in PHP
Quote:
OOP is much easier to understand and also everything is centralised. |
| All times are GMT +5.5. The time now is 13:50. |