Jump to content

Class Usage in PHP?


Liquid Fire

Recommended Posts

I am not putting in O.O.P forum becuase more of a general question.

 

Maybe it is just me or just the code I have looked at but most of the time when i see classes being used in PHP, generally they are just filled with method(function) and no members(variables).  And if they do are a member, generally only one and it is some type of database object.  Most of the time these methods just return arrays or information.  Is there any real good benefit from returning array inside formatting the array in the class into an object and the pass back the object.  I mean if you have a class of functions with no member, then you really don't have a class, just a bunch of functions with kinda of a namespace.  How do you use classes in php?  Do you just use classes to store data your objects needs and not alter any of that information?

Link to comment
https://forums.phpfreaks.com/topic/61853-class-usage-in-php/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.