PHP code example of erickfirmo / dbconnection

1. Go to this page and download the library: Download erickfirmo/dbconnection 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/ */

    

erickfirmo / dbconnection example snippets




  // Require composer autoloader
  g PDO
  $connection = (new \Connection())->getPDOConnection();




  return [

    'host' => 'localhost',
    'driver' => 'mysql',
    'charset' => 'utf-8',
    'database' => '<database_name>',
    'user' => '<database_user>',
    'password' => '<database_password>'
    
  ];