Jump to content

creating objects within objects..


amedhussaini

Recommended Posts

is this a valid practice?  i'm working on my first OOP class that deals with user registration.. can i have a, for example, $sqli = new mysqli(); within the method that will "register" and insert variables into my table?

 

I've found a few tutorials on this.. the one i'm working out of deals with procedurally connecting to the database and inserting information, but can i do it object oriented style?

 

amed

Link to comment
https://forums.phpfreaks.com/topic/103176-creating-objects-within-objects/
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.