1. Go to this page and download the library: Download timesplinter/tsfw-db library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
timesplinter / tsfw-db example snippets
$dbConnect = new DBConnect('localhost', 'my_db', 'my_db_user', 'secret');
$db = new DBMySQL($dbConnect);
$stmnt = $db->prepare("SELECT ID, name, email FROM user WHERE email LIKE ?");
$users = $db->select($stmnt, array('%@example.com%'));
foreach($users as $user) {
echo $user->ID , ', ' , $user->name , '(' , $user->email , ')<br>';
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.