In this article, we will learn the benefits of persistent connection in PDO, in terms of memory usage and time of execution.
The article will only observe connection to MySQL database.
PDO is an abstraction layer for database connections in PHP, and it became increasingly popular in the past few years.
In this article I will explain the method I suggest for hashing password and saving them in a database.
First of all, never insert passwords to the database as plain text!
If your database is stolen your users will pay the price (maybe you will have to pay them for the damage you have [...]
In the past few years ORMs have become increasingly popular; however I, personally, don’t like most of the ORM libraries.
ORMs are used to map data from the database to access it easily, and generally they do make it easier than regular SQL.
Nevertheless, these libraries are usually very heavy (Doctrine is almost 2MB!) [...]