Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
banned banned
Courses Plus Student 11,243 PointsUsing PDO in your classes
So am I able to use PDO in all of my classes? Dependency injection? Using a singleton? What's the way to go? I haven't seen this in the teamtreehouse courses on how to deal with this.
1 Answer
Shawn Gregory
Courses Plus Student 40,672 PointsHello,
I don't usually like to send people outside of the current website they are on especially here at TeamTreehouse, but I moderate a PHP help forum site and one of the other moderators on that forum is a huge PDO freak. If you go here you can get his spiel on the whole PDO subject. Again I don't like to redirect you out of here, but I feel that (in this instant) the forum post in my link will educate you on the different uses that you can do with PDO.
(NOTE: I am not advertising this forum website I am just allowing Mark to get an in-depth explanation from a person whose an avid PDO developer and user.)
Cheers!
banned banned
Courses Plus Student 11,243 Pointsbanned banned
Courses Plus Student 11,243 PointsI already now how to make a connection etc. But how am I able to use the PDO object in all of my classes? Like what's the most convenient way to do this.