4
votes
1answer
91 views

My simple PDO wrapper class

I made a simple database class and I wanted to know if there are any improvements I could work on as far as readability, efficiency, methods and making it modular goes. Any other suggestions are also ...
6
votes
2answers
123 views

My database class extends MySQLi

The following is a small class I extended MySQLi with. I'm going to use this in my upcoming projects, but my main reason to do this class is learning, so I would like to submit this for your review, ...
4
votes
2answers
292 views

Implementation of OOP for retrieving list of objects from database

If I have a Person class that outlines the properties of a person and one of People that just contains a ...
14
votes
1answer
14k views

Very simple PHP PDO class

There are many PHP PDO classes out there, agreed. However I find they do not allow for flexibility. So I created one that helps reduce development time as little as it may be but it does the job ...
5
votes
1answer
615 views

Generic method for database calls

Background Breaking from MVC, I've implemented the following architecture: POST/GET ➤ PHP ➤ Database Calls ➤ XML ➤ XSLT ➤ HTML All database interactions are ...
1
vote
2answers
290 views

PHP Class Inheritance / Object Instantiation / Object / Property Scope w/ Child / Parent Classes & Dependency Container Class

In PHP, I have a parent/child class and am using dependency container to load them. I am trying to use the same database connection on all of them without duplicating the object. CLARIFICATION: MY ...
3
votes
1answer
414 views

Model for web applications

I'm developing a model for web applications. The database that I use is Redis. I created special DbField objects like ...
2
votes
1answer
121 views

Is this an efficient way of accessing the database

**EDIT I asked this question yesteday when I was unregistered, and now I can't seem to comment on the question or mark the answer as correct but I would like to say thank you for taking the time to ...
3
votes
1answer
493 views

Question about User php class. Should I connect to DB in this class?

I have small Class which handles user's information. (name, surname, login, hash of password). Also this class can activate, register and login the user. This means I should connect to DB. Is it ...