1. Go to this page and download the library: Download davmixcool/php-dbcloud 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/ */
davmixcool / php-dbcloud example snippets
//config/database.php
return [
'development' => [
'type' => 'mysql',
'host' => 'localhost',
'port' => '3306',
'user' => 'root',
'pass' => 'password',
'database' => 'test',
// If singleTransaction is set to true, the --single-transcation flag will be set.
'singleTransaction' => false,
// Do not dump the given tables
// Set only table names, without database name
// Example: ['table1', 'table2']
// http://dev.mysql.com/doc/refman/5.7/en/mysqldump.html#option_mysqldump_ignore-table
'ignoreTables' => [],
// using ssl to connect to your database - active ssl-support (mysql only):
'ssl'=>false,
// add additional options to dump-command (like '--max-allowed-packet')
'extraParams'=>null,
],
'production' => [
'type' => 'postgresql',
'host' => 'localhost',
'port' => '5432',
'user' => 'postgres',
'pass' => 'password',
'database' => 'test',
],
]