-
Notifications
You must be signed in to change notification settings - Fork 7
03 Database Access with PDO
Timotheus Pokorra edited this page Jan 29, 2018
·
1 revision
see the intro:
SELECT and INSERT/UPDATE with prepared statements:
We already have a database object created in https://github.com/ICCM-EU/BOF/blob/master/src/dependencies.php#L10
You can access it, by passing the database object to the constructor of the class, that contains your method.
See this commit which illustrates the setup:
I used this explanation for dependency injection of the database connection: