New answers tagged

2 votes

DB Class extending PDO w/ other useful functions

Given that all cosmetic suggestions were already given, I'd concentrate on rather critical flaws. Architecture-wise, such a class shouldn't exist. Technically, it is not even a class at all, but ...
user avatar
3 votes
Accepted

DB Class extending PDO w/ other useful functions

You didn't explain, in your question, what your objectives were with this class. Why encapsulate a PDO class like this? My guess is that you did this to put all your database functions in one place? ...
user avatar
2 votes

DB Class extending PDO w/ other useful functions

Much of my advice can be found in https://www.php-fig.org/psr/psr-12/. The opening curly brace should be on the next line after the declaration. Method names should be camelCase. In most cases, I ...
user avatar
  • 7,711
1 vote

A database trait in Rust. How can I make all these generic parameters easier to use?

For your intricate types I have found another approach: ...
user avatar
  • 91

Top 50 recent answers are included