PHP code example of bushbaby / doctrine-reconnect

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

    

bushbaby / doctrine-reconnect example snippets



return array(
    'doctrine' => array(
        'connection' => array(
            'orm_default' => array(
                'driverClass' => 'BsbDoctrineReconnect\DBAL\Driver\PDOMySql\Driver',
                'wrapperClass' => 'BsbDoctrineReconnect\DBAL\Connection',

                'params' => array(
                    'driverOptions' => array(
                        'x_reconnect_attempts' => 10,
                    ),
                )
            )
        )
    ),
);
sh
php composer.phar